Intermediate
Package: bzip2
bzip2
Compress a file using the bzip2 algorithm.
Syntax
bzip2 [options] file
Description
bzip2 compresses a single file, typically achieving a better compression ratio than gzip at the cost of being slower โ commonly seen as the .bz2 option when downloading source tarballs.
Examples
bzip2 file.txt
Compress a file to file.txt.bz2
bunzip2 file.txt.bz2
Decompress a .bz2 file
tar -cjvf archive.tar.bz2 folder/
Create a bzip2-compressed tar archive directly