home *** CD-ROM | disk | FTP | other *** search
/ Chip 2001 May / W2KPRK.iso / apps / posix / source / MAN / MV.PRT < prev    next >
Text File  |  1999-11-17  |  2KB  |  67 lines

  1.                                                            MV (1)
  2.  
  3. NAME
  4.  
  5.   mv - move files
  6.  
  7. SYNOPSIS
  8.  
  9.   mv [ f ] source target mv [ f ] source ... source
  10. DESCRIPTION
  11.  
  12.   In its first form, the mv utility renames the file named by the
  13. source  operand  to  the  destination  path  named  by the target
  14. operand.  This form is assumed when the  last  operand  does  not
  15. name an already existing directory.
  16.   In its second form, mv  moves  each  file  named  by  a  source
  17. operand  to a destination file in the existing directory named by
  18. the directory operand.  The destination path for each operand  is
  19. the pathname produced by the concatenation of the last operand, a
  20. slash, and the final pathname component of the named file.
  21.   The following options are available:
  22.      f - Do not prompt for confirmation  before  overwriting  the
  23.      destination  path.   (The option is ignored if the option is
  24.      specified.)
  25.      i - Causes mv to write a prompt  to  standard  error  before
  26.      moving a file that would overwrite an existing file.  If the
  27.      response from the standard input begins with  the  character
  28.      ``y'', the move is attempted.
  29.   It is an error for either the source operand or the destination
  30. path to specify a directory unless both do.
  31.   If the destination path does not  have  a  mode  which  permits
  32. writing,  mv  prompts  the user for confirmation as specified for
  33. the option.
  34.   As the rename (2) call does not work across  file  systems,  mv
  35. uses  cp  (1)  and  rm (1) to accomplish the move.  The effect is
  36. equivalent to: rm -f destination_path &&  \  cp  -pr  source_file
  37. destination && \ rm -rf source_file
  38.   The mv utility exits 0 on success, and >0 if an error occurs.
  39. SEE ALSO
  40.  
  41.   cp (1)
  42. STANDARDS
  43.  
  44.   The mv utility is expected to be compatible.
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  
  64.  
  65.  
  66.  
  67.