diff options
author | Jenkins <jenkins@review.openstack.org> | 2012-05-21 16:32:35 -0400 |
---|---|---|
committer | Monty Taylor <mordred@inaugust.com> | 2012-05-21 16:32:35 -0400 |
commit | 471704df644eced17026c280b0aab9e549718e14 (patch) | |
tree | c2d8d0ec74fa45e0b61ca4b2153fb5b0e7bf490d /tools/nova.bash_completion | |
download | python-cinderclient-0.0.tar.gz |
Initial split from python-novaclient.0.0
Diffstat (limited to 'tools/nova.bash_completion')
-rw-r--r-- | tools/nova.bash_completion | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/tools/nova.bash_completion b/tools/nova.bash_completion new file mode 100644 index 0000000..060bf1f --- /dev/null +++ b/tools/nova.bash_completion @@ -0,0 +1,15 @@ +_cinder() +{ + local cur prev opts + COMPREPLY=() + cur="${COMP_WORDS[COMP_CWORD]}" + prev="${COMP_WORDS[COMP_CWORD-1]}" + + opts="$(cinder bash_completion)" + + COMPLETION_CACHE=~/.cinderclient/*/*-cache + opts+=" "$(cat $COMPLETION_CACHE 2> /dev/null | tr '\n' ' ') + + COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) ) +} +complete -F _cinder cinder |