--- a/index.html +++ b/index.html @@ -301,8 +301,11 @@

Compressed files that have suffix ``gz'', ``z'', or ``GZ'', ``Z'' are extracted by lv using zcat (1), - and ``bz2'' or ``BZ2'' with bzcat (1). - Please install zcat and bzcat that can expand all of them. + ``bz2'' or ``BZ2'' with bzcat (1). + ``lzma'' or ``LZMA'' with lzcat (1). + and ``xz'' or ``XZ'' with xzcat (1). + Please install zcat, bzcat, lzcat and xzcat + that can expand all of them.

In case that standard output is not connected to an ordinal terminal but to redirect or pipe-line, --- a/src/stream.c +++ b/src/stream.c @@ -43,6 +43,8 @@ private byte *gz_filter = "zcat"; private byte *bz2_filter = "bzcat"; +private byte *lzma_filter = "lzcat"; +private byte *xz_filter = "xzcat"; private stream_t *StreamAlloc() { @@ -75,10 +77,14 @@ filter = gz_filter; else if( !strcmp( "bz2", exts ) || !strcmp( "BZ2", exts ) ) filter = bz2_filter; + else if( !strcmp( "lzma", exts ) || !strcmp( "LZMA", exts ) ) + filter = lzma_filter; + else if( !strcmp( "xz", exts ) || !strcmp( "XZ", exts ) ) + filter = xz_filter; } if( NULL != filter ){ /* - * zcat or bzcat + * zcat, bzcat, lzcat or xzcat */ if( NULL == (st->fp = (FILE *)tmpfile()) ) perror( "temporary file" ), exit( -1 );