Linux "mv" Command Line Options and Examples
move

Rename SOURCE to DEST, or move SOURCE(s) to DIRECTORY. Mandatory arguments to long options are mandatory for short options too.


Usage:

mv [OPTION]... [-T] SOURCE DEST
    mv [OPTION]... SOURCE... DIRECTORY
    mv [OPTION]... -t DIRECTORY SOURCE...




Command Line Options:

--backup[
make a backup of each existing destination file
mv --backup[ ...
-b
like --backup but does not accept an argument
mv -b ...
-f
do not prompt before overwriting
mv -f ...
-i
prompt before overwrite
mv -i ...
-n
do not overwrite an existing fileIf you specify more than one of -i, -f, -n, only the final one takes effect.
mv -n ...
--strip-trailing-slashes
remove any trailing slashes from each SOURCE argument
mv --strip-trailing-slashes ...
-S
override the usual backup suffix
mv -S ...
-t
move all SOURCE arguments into DIRECTORY
mv -t ...
-T
treat DEST as a normal file
mv -T ...
-u
move only when the SOURCE file is newer than the destination file or when the destination file is missing
mv -u ...
-v
explain what is being done
mv -v ...
-Z
set SELinux security context of destination file to default type
mv -Z ...
--help
display this help and exit
mv --help ...
--version
output version information and exitThe backup suffix is '~', unless set with --suffix or SIMPLE_BACKUP_SUFFIX. The version control method may be selected via the
mv --version ...
--backup
none, offnever make backups (even if --backup is given)numbered, tmake numbered backupsexisting, nilnumbered if numbered backups exist, simple otherwisesimple, neveralways make simple backupsAUTHORWritten by Mike Parker, David MacKenzie, and Jim Meyering.REPORTING BUGSGNU coreutils online help: <http://www.gnu.org/software/coreutils/>Report mv translation bugs to <http://translationproject.org/team/>COPYRIGHTCopyright © 2017 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>.This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.
mv --backup ...