Compressing and Decompressing Xz Archives on Command Line
The simplest way to create an xz archive is by invoking the xz commandand specifying the name of the file you wish to compress. As you can see Compressing and Decompressing Xz Archives in Gui
Creating or decompressing archives on GUI is going to vary a little, depending on which desktop environment you’re running Closing Thoughts
In this guide, we saw how to use xz compression on command line and GUI to create and decompress xz archives XZ is a general purpose data compression format with high compression ratio and relatively fast decompression. The primary compression algorithm (filter) is
LZMA2. Additional filters can be used to improve compression ratio even further. E.g. Branch/Call/Jump (BCJ) filters improve compression ratio of executable data.
xz is a general-purpose data compression tool with command line syntax similar to gzip (1) and bzip2 (1). The native file format is the .xz format, but also the legacy .lzma format and raw compressed streams with no container format headers are supported. xz compresses or decompresses each file according to the selected operation mode.
Much like a.
ZIP file, an XZ file contains files that have been compressed so they can be stored and shared with others more easily. Users often use XZ files to share compressed files over the Internet, via email, and on USB drives. XZ compression compresses files to smaller sizes than some alternatives, such as gzip and bzip2 compression.Let’s use xz to compress a single file. Except for the program name, the usage is identical to gzip:
xz -v data.csv This command compresses the file data.csv and replaces it with the file data.csv.xz. The -v option lets xz display progress information. xz has the same compression levels 1-9 as gzip. The default compression is 6.
xz compresses or decompresses each file according to the selected operation mode. If no files are given or file is -, xz reads from standard input and writes the processed data to standard output. xz will refuse (display an error and skip the file) to write compressed data to standard output if it is a terminal.