[Bash-completion-commits] [bash-completion] 04/04: pigz, unpigz: Handle *.zz

Ville Skyttä scop-guest at moszumanska.debian.org
Wed Sep 17 16:41:32 UTC 2014


This is an automated email from the git hooks/post-receive script.

scop-guest pushed a commit to branch master
in repository bash-completion.

commit 4038c71357dd85ee049363c6c48c513e1c1c263d
Author: Ville Skyttä <ville.skytta at iki.fi>
Date:   Wed Sep 17 19:40:02 2014 +0300

    pigz, unpigz: Handle *.zz
---
 bash_completion  | 3 ++-
 completions/gzip | 1 +
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/bash_completion b/bash_completion
index 3bb4bc2..57423ab 100644
--- a/bash_completion
+++ b/bash_completion
@@ -1879,7 +1879,8 @@ _install_xspec '!*.?(t)bz?(2)' bunzip2 bzcat pbunzip2 pbzcat lbunzip2 lbzcat
 _install_xspec '!*.@(zip|[ejsw]ar|exe|pk3|wsz|zargo|xpi|s[tx][cdiw]|sx[gm]|o[dt][tspgfc]|od[bm]|oxt|epub|apk|do[ct][xm]|p[op]t[mx]|xl[st][xm])' unzip zipinfo
 _install_xspec '*.Z' compress znew
 # zcmp, zdiff, z*grep, zless, zmore intentionally not here, see Debian: #455510
-_install_xspec '!*.@(Z|[gGd]z|t[ag]z)' gunzip zcat unpigz
+_install_xspec '!*.@(Z|[gGd]z|t[ag]z)' gunzip zcat
+_install_xspec '!*.@(Z|[gGdz]z|t[ag]z)' unpigz
 _install_xspec '!*.Z' uncompress
 # lzcmp, lzdiff intentionally not here, see Debian: #455510
 _install_xspec '!*.@(tlz|lzma)' lzcat lzegrep lzfgrep lzgrep lzless lzmore unlzma
diff --git a/completions/gzip b/completions/gzip
index 300785d..3f3bf75 100644
--- a/completions/gzip
+++ b/completions/gzip
@@ -23,6 +23,7 @@ _gzip()
     fi
 
     local IFS=$'\n' xspec="*.@(gz|t[ag]z)"
+    [[ ${1##*/} == pigz ]] && xspec="*.@([gz]z|t[ag]z)"
 
     if [[ "$prev" == --* ]]; then
         [[ "$prev" == --@(decompress|list|test) ]] && xspec="!"$xspec

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/bash-completion/bash-completion.git



More information about the Bash-completion-commits mailing list