Linux - cut rename command

For moving (copying and cutting) files into the destination folder, the command is as follows:

①Command: mv The name of the file to be removed.txt Target folder/

For renaming files, you can use the GUI method, or you can operate the terminal command line, that is, move the file to its same-level directory and change the name. The command is as follows:

②Command: mv original file name.txt new file name.txt

③Command: mv folder name to be removed/target folder/  (move folder)   

④Command : mv target folder/ folder name to be removed/.    (move back)   

For those who just want to move all the files in the folder without moving the folder itself, the command is as follows:

⑤Command : mv folder name to be removed/* target folder/     

If you just want to move a specific type of file (txt) in a folder without moving the folder itself, the command is as follows:

⑤Command : mv folder name to be removed/*.txt target folder/     

Guess you like

Origin blog.csdn.net/butnotif/article/details/128687405