Linux commands specific explanations (2) –MV

Source: Internet
Author: User

File Location:
MV:/bin/mv/usr/share/man/man1/mv.1.gz

Name:
Mv-move (rename) files

How to use:
MV [OPTION] ... [-T] SOURCE DEST
MV [OPTION] ... SOURCE ... DIRECTORY
MV [OPTION] ...-t DIRECTORY SOURCE ...

Descriptive narrative:
Rename the source file to dest, or move one or more source files to the directory directory

--backup[=control]
Back up each file that already exists in the target directory
Unless--suffix or simple_backup_suffix is set, the default backup file suffix is ' ~ '.


You can set the backup method by specifying a control variable, or by setting the environment variable Version_control to the lower face value:
None, off
Never make a backup (regardless of whether--backup is specified)

Numbered, T
Create a backup with a digital index

Existing, nil
Suppose you have a backup with a digital index that uses a digital index backup. Otherwise, use normal backup

Simple, never
Always use normal backup


-B

--backup the version number without the number of references

-F,--force
No need to confirm when overwriting existing files


-I.,--interactive
Need to be confirmed when overwriting existing files


-N,--no-clobber
Do not overwrite existing files
Assuming that-i,-f,-n is specified at the same time, the last one takes effect


--strip-trailing-slashes
Remove the/From the end of each source file (involving a copy of the directory and link file)
References: http://gnu-coreutils.7620.n7.nabble.com/mv-trailing-slash-warning-td975.html

-S,--suffix=suffix
Change the default backup file suffix


-T,--target-directory=directory
Move all source files to the directory folder


-T,--no-target-directory
Dest is treated as a normal file, assuming that dest is a directory, the source file will not be moved to the directory


-U,--update
Move only if the source file is newer than the target file or if the destination file is missing

-V,--verbose
Output Run Process


--help

Display Help information

--version
Display version number information

Linux commands specific explanations (2) –MV

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.