summaryrefslogtreecommitdiff
path: root/completions/_svnadmin
diff options
context:
space:
mode:
Diffstat (limited to 'completions/_svnadmin')
-rw-r--r--completions/_svnadmin20
1 files changed, 10 insertions, 10 deletions
diff --git a/completions/_svnadmin b/completions/_svnadmin
index 7a86c43e..654fd3ec 100644
--- a/completions/_svnadmin
+++ b/completions/_svnadmin
@@ -12,11 +12,11 @@ _svnadmin()
commands='create deltify dump help ? hotcopy list-dblogs list-unused-dblogs
load lslocks lstxns recover rmlocks rmtxns setlog verify'
- if [[ $cword -eq 1 ]]; then
- if [[ "$cur" == -* ]]; then
- COMPREPLY=( $(compgen -W '--version' -- "$cur") )
+ if ((cword == 1)); then
+ if [[ $cur == -* ]]; then
+ COMPREPLY=($(compgen -W '--version' -- "$cur"))
else
- COMPREPLY=( $(compgen -W "$commands" -- "$cur") )
+ COMPREPLY=($(compgen -W "$commands" -- "$cur"))
fi
else
case $prev in
@@ -25,14 +25,14 @@ _svnadmin()
return
;;
--fs-type)
- COMPREPLY=( $(compgen -W 'fsfs bdb' -- "$cur") )
+ COMPREPLY=($(compgen -W 'fsfs bdb' -- "$cur"))
return
;;
esac
local command=${words[1]}
- if [[ "$cur" == -* ]]; then
+ if [[ $cur == -* ]]; then
# possible options for the command
local options
case $command in
@@ -62,10 +62,10 @@ _svnadmin()
esac
options+=" --help"
- COMPREPLY=( $(compgen -W "$options" -- "$cur") )
+ COMPREPLY=($(compgen -W "$options" -- "$cur"))
else
- if [[ "$command" == @(help|[h?]) ]]; then
- COMPREPLY=( $(compgen -W "$commands" -- "$cur") )
+ if [[ $command == @(help|[h?]) ]]; then
+ COMPREPLY=($(compgen -W "$commands" -- "$cur"))
else
_filedir
fi
@@ -73,6 +73,6 @@ _svnadmin()
fi
} &&
-complete -F _svnadmin -o default svnadmin
+ complete -F _svnadmin -o default svnadmin
# ex: filetype=sh