diff options
Diffstat (limited to 'completions/rrdtool')
-rw-r--r-- | completions/rrdtool | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/completions/rrdtool b/completions/rrdtool index c8214a49..dcb9ce67 100644 --- a/completions/rrdtool +++ b/completions/rrdtool @@ -1,17 +1,17 @@ # bash completion for rrdtool -*- shell-script -*- -_rrdtool () +_rrdtool() { local cur prev words cword _init_completion || return - if [[ ${#words[@]} -eq 2 ]]; then - COMPREPLY=( $(compgen -W 'create update updatev graph dump restore - last lastupdate first info fetch tune resize xport' -- "$cur") ) + if ((${#words[@]} == 2)); then + COMPREPLY=($(compgen -W 'create update updatev graph dump restore + last lastupdate first info fetch tune resize xport' -- "$cur")) else _filedir rrd fi } && -complete -F _rrdtool rrdtool + complete -F _rrdtool rrdtool # ex: filetype=sh |