Skip to content

Commit

Permalink
fix(lzip): fix broken case patterns for long and short options
Browse files Browse the repository at this point in the history
The original codes before PR 862,

https://github.com/scop/bash-completion/pull/862/files#diff-87387e55a9536f7ac2aa5fce39d9a0442c29ec2058215563388d5a284a9ac1c1L15-R24

were already broken.  According to the man page of lzip, lzip supports
separate options `--decompress` and `-d`, but there are no options
`--decompress-d` or `--decompress-...d`.  In this patch, we separate
these unexpectedly combined option names.

Reference:

scop#914 (comment)

Co-authored-by: Ville Skyttä <[email protected]>
  • Loading branch information
akinomyoga and scop committed Apr 16, 2023
1 parent b061c76 commit 9f4785d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions completions/lzip
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ _lzip()
--volume-size | --data-size | -${noargopts}@([bmsSB]|[hV]*))
return
;;
--decompress-${noargopts}d)
--decompress | -${noargopts}d)
decompress=true
;;
--threads-${noargopts}n)
--threads | -${noargopts}n)
COMPREPLY=($(compgen -W "{1..$(_ncpus)}" -- "$cur"))
return
;;
--output-${noargopts}o)
--output | -${noargopts}o)
_filedir
return
;;
Expand Down

0 comments on commit 9f4785d

Please sign in to comment.