compsize
Calculate the compression ratio of a set of files on a btrfs filesystem. tldr-pages
On Linux
Linux
Calculate the current compression ratio for a file or directory
sudo compsize path/to/file_or_directoryIdentifyDon't traverse filesystem boundaries
sudo compsize --one-file-system path/to/file_or_directoryIdentifyShow raw byte counts instead of human-readable sizes
sudo compsize --bytes path/to/file_or_directoryIdentify