[0m


CP(1)		    UNIX Programmer's Manual		    CP(1)



[1mNAME
     [0mcp, cp0 - copy

[1mSYNOPSIS
     cp [0m[ [1m-ip [0m] file1 file2

     [1mcp [0m[ [1m-ipr [0m] file ... directory

[1mDESCRIPTION
     [0m_F_i_l_e_1 is copied onto _f_i_l_e_2.  By default, the mode and owner
     of _f_i_l_e_2 are preserved if it already existed; otherwise the
     mode of the source file modified by the current _u_m_a_s_k(2) is
     used.  The [1m-p [0moption causes _c_p to attempt to preserve
     (duplicate) in its copies the modification times and modes
     of the source files, ignoring the present _u_m_a_s_k.

     In the second form, one or more _f_i_l_e_s are copied into the
     _d_i_r_e_c_t_o_r_y with their original file-names.

     _C_p refuses to copy a file onto itself.

     If the [1m-i [0moption is specified, _c_p will prompt the user with
     the name of the file whenever the copy will cause an old
     file to be overwritten. An answer of `y' will cause _c_p to
     continue. Any other answer will prevent it from overwriting
     the file.

     If the [1m-r [0moption is specified and any of the source files
     are directories, _c_p copies each subtree rooted at that name;
     in this case the destination must be a directory.

[1mSEE ALSO
     [0mcat(1), mv(1), rcp(1C)

[1mBUGS
     [0m_C_p will create `holes' in the output file for completely
     zero disc blocks, this saves considerable disc space on RIS-
     CiX systems. Some NFS fileservers (e.g. those running
     4.2BSD) have a bug which cause them to add a zero byte to
     files copied in this manner.  This can be avoided by using
     _c_p_0 which is identical to _c_p except that it copies the file
     byte for byte.













Printed 26/10/92    Revision 1.6 of 02/07/90			1



[0m