summaryrefslogtreecommitdiff
path: root/completions/sitecopy
diff options
context:
space:
mode:
Diffstat (limited to 'completions/sitecopy')
-rw-r--r--completions/sitecopy22
1 files changed, 11 insertions, 11 deletions
diff --git a/completions/sitecopy b/completions/sitecopy
index dae0548d..85156875 100644
--- a/completions/sitecopy
+++ b/completions/sitecopy
@@ -9,17 +9,17 @@ _sitecopy()
_init_completion -s || return
case $prev in
- --debug|-!(-*)d)
- COMPREPLY=( $(compgen -W "socket files rcfile ftp http httpbody
- rsh sftp xml xmlparse cleartext" -- "$cur") )
+ --debug | -!(-*)d)
+ COMPREPLY=($(compgen -W "socket files rcfile ftp http httpbody
+ rsh sftp xml xmlparse cleartext" -- "$cur"))
compopt -o nospace
return
;;
- --logfile|--rcfile|-!(-*)[gr])
+ --logfile | --rcfile | -!(-*)[gr])
_filedir
return
;;
- --storepath|-!(-*)p)
+ --storepath | -!(-*)p)
_filedir -d
return
;;
@@ -27,24 +27,24 @@ _sitecopy()
case $cur in
--*)
- COMPREPLY=( $(compgen -W "$(_parse_help $1)" -- "$cur") )
- [[ $COMPREPLY == *= ]] && compopt -o nospace
+ COMPREPLY=($(compgen -W "$(_parse_help $1)" -- "$cur"))
+ [[ ${COMPREPLY-} == *= ]] && compopt -o nospace
return
;;
# only complete long options
-)
compopt -o nospace
- COMPREPLY=( -- )
+ COMPREPLY=(--)
return
;;
esac
if [[ -r ~/.sitecopyrc ]]; then
- COMPREPLY=( $(compgen -W "$($1 -v | \
- command sed -n '/^Site:/s/Site: //p')" -- "$cur") )
+ COMPREPLY=($(compgen -W "$($1 -v |
+ command sed -n '/^Site:/s/Site: //p')" -- "$cur"))
fi
} &&
-complete -F _sitecopy -o default sitecopy
+ complete -F _sitecopy -o default sitecopy
# ex: filetype=sh