Open System Services Shell and Utilities Reference Manual (G06.27+, H06.04+)

User Commands (v - z) zcat(1)
NAME
zcat - Expands compressed data
SYNOPSIS
zcat [-n][le[.Z] ... ]
FLAGS
-n Species that no header is added or expected. This ag might be useful for expanding
old les.
DESCRIPTION
The zcat command writes the uncompressed version of a compressed le to the standard output
le. The compressed (.Z) le remains intact.
zcat is identical to the command uncompress -c.
You can specify the compressed target le with or without the .Z sufx; if you do not specify the
sufx, zcat assumes it. If you do not specify a le or if you specify - by itself, then the zcat com-
mand expands the standard input le.
Operands
file[.Z] Species the pathname of the compressed le to be expanded. If the .Z sufxis
omitted, it is assumed.
Environment Variables
This command supports the use of the LANG, LC_ALL, LC_CTYPE, LC_MESSAGES, and
NLSPATH environment variables.
EXIT VALUES
The zcat command returns the following values:
0 (zero) The command completed successfully.
>0 An error occurred or an attempt was made to expand a le that is not
compressed.
RELATED INFORMATION
Commands: compress(1), uncompress(1).
STANDARDS CONFORMANCE
This command conforms to the XPG4 Version 2 specication with extensions.
527188-004 Hewlett-Packard Company 1045