Name
cpio
Synopsis
cpio control_options [options]
Copies file archives in from or out to disk or to another location on
the local machine. Note that until native drivers for tape drives
exist for Mac OS X, cpio cannot write to tape.
Each of the three control options, -i,
-o, or -p accepts different
options. (See also ditto, pax
and tar.)
cpio does not preserve resource forks or metadata
when copying files that contain them. For such files, use
ditto instead.
-
cpio -i [options] [patterns] Copy in (extract) files whose names match selected patterns. Each pattern can include filename metacharacters from the Bourne shell. (Patterns should be quoted or escaped so they are interpreted by
cpio, not by the shell.) If no pattern is used, all files are copied in. During extraction, existing files are not overwritten by older versions in the archive (unless-uis specified).-
cpio -o [options] Copy out a list of files whose names are given on the standard input.
-
cpio -p [options]directory Copy files to another directory on the same system. Destination pathnames are interpreted relative to the named directory.
Comparison of valid options
Options available to the -i,
-o, and -p options are shown
respectively in the first, second, and third row below. (The
- is omitted for clarity.)
i:6 b B c C d E f H I m r s S t u vo:a A B c C H L O vp:a d l L m u v
Options
-
-a Reset access times of input files.
-
-A Append files to an archive (must use with
-O).-
-b Swap bytes and half-words. Words ...