summaryrefslogtreecommitdiff
path: root/completions/gzip
diff options
context:
space:
mode:
Diffstat (limited to 'completions/gzip')
-rw-r--r--completions/gzip13
1 files changed, 6 insertions, 7 deletions
diff --git a/completions/gzip b/completions/gzip
index 59818d92..d3bce282 100644
--- a/completions/gzip
+++ b/completions/gzip
@@ -6,18 +6,17 @@ _gzip()
_init_completion || return
case $prev in
- -b|--blocksize|-S|--suffix|-h|--help|-V|--version)
+ --blocksize|--suffix|--help|--version|-!(-*)[bShV])
return
;;
- -p|--processes)
- COMPREPLY=( $( compgen -W "{1..$(_ncpus)}" -- "$cur" ) )
+ --processes|-!(-*)p)
+ COMPREPLY=( $(compgen -W "{1..$(_ncpus)}" -- "$cur") )
return
;;
esac
if [[ "$cur" == -* ]]; then
- COMPREPLY=( $( compgen -W '$( _parse_help "$1" ) {-1..-9}' \
- -- "$cur" ) )
+ COMPREPLY=( $(compgen -W '$(_parse_help "$1") {-1..-9}' -- "$cur") )
[[ $COMPREPLY == *= ]] && compopt -o nospace
return
fi
@@ -36,8 +35,8 @@ _gzip()
_tilde "$cur" || return
compopt -o filenames
- COMPREPLY=( $( compgen -f -X "$xspec" -- "$cur" ) \
- $( compgen -d -- "$cur" ) )
+ COMPREPLY=( $(compgen -f -X "$xspec" -- "$cur") \
+ $(compgen -d -- "$cur") )
} &&
complete -F _gzip gzip pigz