LinuxCommandLibrary

lzcat

TLDR

Decompress to stdout

$ lzcat [file.lz]
copy
Decompress multiple files
$ lzcat [file1.lz] [file2.lz]
copy
Decompress and pipe
$ lzcat [archive.tar.lz] | tar -xf -
copy
Verbose output
$ lzcat -v [file.lz]
copy

SYNOPSIS

lzcat [options] [files...]

DESCRIPTION

lzcat decompresses lzip files to standard output. It's equivalent to "lzip -dc" and functions like zcat for gzip files.
lzcat is useful for viewing compressed files or piping decompressed data to other programs without creating intermediate files.

PARAMETERS

-v, --verbose

Verbose output.
-q, --quiet
Suppress warnings.
-t, --test
Test integrity.
--help
Show help.
--version
Show version.

EXAMPLE USAGE

$ # View compressed log
lzcat system.log.lz | less

# Extract tar archive
lzcat archive.tar.lz | tar xvf -

# Compare compressed files
diff <(lzcat file1.lz) <(lzcat file2.lz)
copy

CAVEATS

Only handles lzip format. For other formats use zcat, xzcat, bzcat. Cannot compress; use lzip for that.

HISTORY

lzcat is part of the lzip package created by Antonio Diaz Diaz as a cleaner implementation of LZMA compression.

SEE ALSO

lzip(1), zcat(1), xzcat(1), bzcat(1)

Copied to clipboard