866 B
866 B
title
| title |
|---|
| Bash mv |
Bash command: mv
Rename file.
mv <source> <target>
Moves files and folders.
mv <source> <path + filename>
The first argument is the file you want to move, and the second is the location to move it to. It can also be used to rename a file, by inputting 2 file names as parameters, like so: mv originalFilename.txt newFilename.txt
Commonly used options:
-fto force move them and overwrite files without checking with the user.-ito prompt confirmation before overwriting files.-ndo not overwrite an existing file
Warning
This command is capable of modifying many files at once with ease. This can be beneficial, but also dangerous. Use at your own risk