zstd icon indicating copy to clipboard operation
zstd copied to clipboard

--exclude-compressed in environement variable

Open Pascal76 opened this issue 1 year ago • 6 comments

--exclude-compressed is not usable when using tar command for backups for ex.

tar cf $FILE.zst --use-compress-program zstd

Would be great to be able to ignore already compressed files in this case and probably other ones.

Pascal76 avatar Mar 27 '24 10:03 Pascal76

Did you mean:

tar -cf $FILE.tar.zst -I 'zstd' .

Cyan4973 avatar Mar 28 '24 05:03 Cyan4973

sorry I don't understand your question.

-I = --use-compress-program also I did not added the directory to backup ... but that is not interesting

For zstd, --exclude-compressed should be the default value, from my point of view, for a compressor reputed for its velocity

Pascal76 avatar Mar 28 '24 06:03 Pascal76

I disagree. Sometimes there is a benefit to double compressing so zstd should not be forcing --exclude-compressed on everyone. You can include it yourself

tar cf $FILE.zst --use-compress-program 'zstd --exclude-compressed'

gcflymoto avatar Mar 28 '24 19:03 gcflymoto

ok some people may want double compressing, and for some cases too sometimes the compression is better.

Do you double compress zstd files too ?

Thank you for the command line.

Pascal76 avatar Mar 28 '24 19:03 Pascal76

Not double .zst, but gzip+bzip2 or gzip+zstd can be a worthwhile combination

gcflymoto avatar Mar 28 '24 20:03 gcflymoto

I disagree. Sometimes there is a benefit to double compressing so zstd should not be forcing --exclude-compressed on everyone. You can include it yourself

tar cf $FILE.zst --use-compress-program 'zstd --exclude-compressed'

I totally agree - this option should not be enabled by default.

lelik107 avatar Mar 29 '24 07:03 lelik107