pack

NAME

pack - compress files

SYNOPSIS

pack [-f] [-] file ...

DESCRIPTION

The pack(1) utility compresses one or more specified files, and stores the compressed versions in files identified by the name file.z. The specified file can include the .z suffix. If the calling process has the appropriate privileges, the original file is removed. To restore a packed file, use unpack(1) or pcat(1).

For each packed file, pack(1) writes to standard output one of the lines:

pack: file: percent% Compression
or
pack: file: no saving - file unchanged
where file is the file name and percent is the percent compression.

A file will not be packed if:


The pack(1) utility takes the following options:

-f
Force packing of files.
-
If one of the operands is -, pack(1) writes to standard output the number of times each byte is used, its relative frequency, and the code for that byte. Subsequent uses of - instead of file on the command line turn this feature off and on.

DIAGNOSTICS

The pack(1) utility exits with a status of 0 for success and >0 if an error occurred.

NOTES

Traditional implementations of pack(1) use Huffman encoding. This implementation is a link to the gzip(1) program, and uses the compression algorithms available to gzip(1).

SEE ALSO

pcat(1)

unpack(1)