MPE/iX Shell and Utilities Reference Manual, Vol 2
pax(1) MPE/iX Shell and Utilities pax(1)
On systems with fixed length records, this might mean padding with blanks to the
record length. On UNIX and POSIX-compliant systems, pax removes all carriage
return characters (\r) and retains only the newline (\n) characters.
It might be desirable to have this option work when creating output to convert text to
a system-independent format; however, due to the format of an archive file, this
would (unacceptably) require all files to be read twice.
–r reads an archive file from standard input.
–s substitute
modifies path names using a substitution command substitute. This is similar to the
substitution command of the ed(1) text editor. The full option has the form
-s /bregexp/string/[gp]
where bregexp is a basic regular expression (see regexp(3)) and string is a string
that pax is to insert in place of matches for the regular expression. string can con-
tain an ampersand & (standing for the string matching bregexp), or \1, \2, and so on
(with the meanings defined in regexp(3)), for subexpression matching.
Normally, –s only replaces the first match for bregexp.Ag following the string
replaces all matches in the line.
A p following the string prints all successful substitutions on the standard error
stream. pax displays a substitution in the format
oldname >> newname
In this form of the command, the slash (/) is used as the character separating parts of
substitute; you can use any non-null character instead.
There may be more than one –s option on the command line. In this case, pax tries
the substitutions in the order given. pax stops trying to make these substitutions as
soon as it makes its first successful substitution. If the null string replaces a file
name, pax ignores that file name on both input and output.
–t after reading files being archived, pax resets the access time to that prior to pax’s
access.
–u compares component dates to dates of existing files with the same name. In read
mode, pax only extracts a file if its modification date is more recent than the modifi-
cation date on an existing file of the same name. In other words, it doesn’t overwrite
an existing file if the existing file is newer than the one in the archive.
Similarly, in copy mode, pax does not overwrite an existing file if the existing file is
newer than the one being copied.
1-420 Commands and Utilities