Linux – Command: move all files inside a directory to another directory (including hidden files)

command-line-interfacelinuxmvshell

I tried to move all files inside a directory to another directory like this:

$ mv /directory_one/* /directory

However, the hidden files (such as .htaccess) in /directory_one won't be moved.

What is the right command to do so?

Best Answer

This should do it:

mv /directory_one/* /directory_one/.* /directory

It will move regular files and dotfiles.