diff options
Diffstat (limited to 'completions/lpr')
-rw-r--r-- | completions/lpr | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/completions/lpr b/completions/lpr index 9a9e8639..554f0534 100644 --- a/completions/lpr +++ b/completions/lpr @@ -7,27 +7,27 @@ _lpr() case $prev in -P) - COMPREPLY=( $(compgen -W "$(lpstat -a 2>/dev/null | cut -d' ' -f1)" -- "$cur") ) + COMPREPLY=($(compgen -W "$(lpstat -a 2>/dev/null | cut -d' ' -f1)" -- "$cur")) return ;; -U) - COMPREPLY=( $(compgen -u -- "$cur") ) + COMPREPLY=($(compgen -u -- "$cur")) return ;; -o) - COMPREPLY=( $(compgen -W "media= landscape orientation-requested= sides= fitplot number-up= scaling= cpi= lpi= page-bottom= page-top= page-left= page-right=" -- "$cur") ) - [[ $COMPREPLY == *= ]] && compopt -o nospace + COMPREPLY=($(compgen -W "media= landscape orientation-requested= sides= fitplot number-up= scaling= cpi= lpi= page-bottom= page-top= page-left= page-right=" -- "$cur")) + [[ ${COMPREPLY-} == *= ]] && compopt -o nospace return ;; esac - if [[ "$cur" == - ]]; then - COMPREPLY=( $(compgen -W '-E -H -C -J -T -P -U -h -l -m -o -p -q -r' -- "$cur") ) + if [[ $cur == - ]]; then + COMPREPLY=($(compgen -W '-E -H -C -J -T -P -U -h -l -m -o -p -q -r' -- "$cur")) return fi _filedir } && -complete -F _lpr lpr + complete -F _lpr lpr # ex: filetype=sh |