-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implment more gzip compatibility (#3037)
-n --no-name is the current behavior already, so we can implement this as a noop. --best is an alias for -9 in gzip add basic cli tests.
- Loading branch information
1 parent
7e364e8
commit 479ef20
Showing
2 changed files
with
28 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#!/bin/sh | ||
|
||
set -e | ||
|
||
# Uncomment the set -v line for debugging | ||
# set -v | ||
|
||
# Test gzip specific compression option | ||
gzip --fast file ; gzip -d file.gz | ||
gzip --best file ; gzip -d file.gz | ||
|
||
# Test -n / --no-name: do not embed original filename in archive | ||
gzip -n file ; grep -qv file file.gz ; gzip -d file.gz | ||
gzip --no-name file ; grep -qv file file.gz ; gzip -d file.gz | ||
gzip -c --no-name file | grep -qv file | ||
|
||
rm -f gzip |