diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 01:03:18 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 01:03:18 +0000 |
commit | f2621414ee5f2f601424c22f00e207903e3b6104 (patch) | |
tree | 56a856dafd1ca684bb23263cacaa723ee4f404fc /completions/optipng | |
parent | Adding debian version 1:2.11-8. (diff) | |
download | bash-completion-f2621414ee5f2f601424c22f00e207903e3b6104.tar.xz bash-completion-f2621414ee5f2f601424c22f00e207903e3b6104.zip |
Merging upstream version 1:2.12.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'completions/optipng')
-rw-r--r-- | completions/optipng | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/completions/optipng b/completions/optipng index 0f6b40e..a81ffa2 100644 --- a/completions/optipng +++ b/completions/optipng @@ -1,52 +1,51 @@ # optipng(1) completion -*- shell-script -*- -_optipng() +_comp_cmd_optipng() { - local cur prev words cword - _init_completion || return + local cur prev words cword comp_args + _comp_initialize -- "$@" || return case $prev in -'?' | -h | --help | -f) return ;; -o) - COMPREPLY=($(compgen -W '{0..7}' -- "$cur")) + _comp_compgen -- -W '{0..7}' return ;; -out | -log) - _filedir + _comp_compgen_filedir return ;; -dir) - _filedir -d + _comp_compgen_filedir -d return ;; -i) - COMPREPLY=($(compgen -W '0 1' -- "$cur")) + _comp_compgen -- -W '0 1' return ;; -zc | -zm) - COMPREPLY=($(compgen -W '{1..9}' -- "$cur")) + _comp_compgen -- -W '{1..9}' return ;; -zw) - COMPREPLY=($(compgen -W '256 512 1k 2k 4k 8k 16k 32k' \ - -- "$cur")) + _comp_compgen -- -W '256 512 1k 2k 4k 8k 16k 32k' return ;; -strip) - COMPREPLY=($(compgen -W 'all' -- "$cur")) + _comp_compgen -- -W 'all' return ;; esac if [[ $cur == -* ]]; then - COMPREPLY=($(compgen -W '$(_parse_help "$1")' -- "$cur")) + _comp_compgen_help return fi - _filedir '@(png|bmp|gif|pnm|tif?(f))' + _comp_compgen_filedir '@(png|bmp|gif|pnm|tif?(f))' } && - complete -F _optipng optipng + complete -F _comp_cmd_optipng optipng # ex: filetype=sh |