Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ cp(1) — DG/UX 5.4.2T

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

chmod(1)

cpio(1)

rm(1)



cp(1)                      C2 Trusted DG/UX 5.4.2T                     cp(1)


NAME
       cp - copy files

SYNOPSIS
       cp [ -i ] [ -p ] [ -r ] file1 [ file2 ...] target

DESCRIPTION
       The cp command copies filen to target.  filen and target may not have
       the same name.  (Care must be taken when using sh(1) metacharacters.)
       If target is not a directory, only one file may be specified before
       it; if it is a directory, more than one file may be specified.  If
       target does not exist, cp creates a file named target.  If target
       exists and is not a directory, its contents are overwritten.  If
       target is a directory, the file(s) are copied to that directory.

       The following options are recognized:


       -i     cp will prompt for confirmation whenever the copy would
              overwrite an existing target.  A y answer means that the copy
              should proceed.  Any other answer prevents cp from overwriting
              target.

       -p     cp will duplicate not only the contents of filen, but also
              preserves the modification time, permission modes and security
              attributes.

       -r     If filen is a directory, cp will copy the directory and all
              its files, including any subdirectories and their files;
              target must be a directory.

       If filen is a directory, target must be a directory in the same
       physical file system.  target and filen do not have to share the same
       parent directory.

       If filen is a file and target is a link to another file with links,
       the other links remain and target becomes a new file.

       If target does not exist, cp creates a new file named target.
       target's security attributes and mode will be set to those of filen
       except that the sticky bit is not set unless the user is a privileged
       user; the owner and group of target are those of the user.

       If target is a file, its contents are overwritten, but the mode,
       security attributes, owner, and group associated with it are not
       changed.  The last modification time of target and the last access
       time of filen are set to the time the copy was made.

       If target is a directory, then for each file named, a new file with
       the same mode and security attributes is created in the target
       directory; the owner and the group are those of the user making the
       copy.





Licensed material--property of copyright holder(s)                         1




cp(1)                      C2 Trusted DG/UX 5.4.2T                     cp(1)


NOTES
       A double dash (--) permits the user to mark the end of any command
       line options explicitly, thus allowing cp to recognize filename
       arguments that begin with a dash (-).  If a double dash (--) and a
       dash (-) both appear on the same command line, the second will be
       interpreted as a filename.

SEE ALSO
       chmod(1), cpio(1), rm(1).
















































Licensed material--property of copyright holder(s)                         2


Typewritten Software • bear@typewritten.org • Edmonds, WA 98026