PMV(1P)
NAME
pmv − move or rename files
SYNOPSIS
pmv [−fi] [−] file1 file2
pmv [−fi] [−] file ... dirname
DESCRIPTION
Pmv moves (changes the name of) file1 to file2. If file2 already exists, it is removed before file1 is moved. If file2 has a mode that forbids writing, pmv prints the mode and reads the standard input to obtain a line. The move takes place only if the line begins with y. In the second form, one or more files are moved to dirname with their original file names.
File and dirname may be either regular or project pathnames. However, because pmv interprets both file and dirname arguments as project pathnames, if file matchs the name of a project directory within the same project, then pmv will print the error message ‘pmv: can’t move project directory file’, unless file is disguised as ./file.
Pmv blindly supercedes existing files unless the −i option is specified.
Pmv refuses to move a file onto itself.
OPTIONS
−fStands for force. This option
overrides any mode restrictions and the −i switch.
−iInteractive mode. Whenever a move is to supercede an existing file, the user is prompted by the name of the file followed by a question mark. If answered with a line starting with ‘y’, the move continues. Any other reply prevents the move from occurring.
−Interpret all the following arguments to pmv as file names. This allows file names starting with minus.
SEE ALSO
DIAGNOSTICS
Exit status 0 is normal. Exit status 1 indicates an error.
AUTHOR
Peter J. Nicklin
BUGS
If file1 and file2 lie on different file systems, pmv must copy the file and delete the original. In this case the owner name becomes that of the copying process and any linking relationship with other files is lost.