summaryrefslogtreecommitdiffstats
path: root/share/bash-completion/container
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@open-infrastructure.net>2016-10-25 13:55:31 +0000
committerDaniel Baumann <daniel.baumann@open-infrastructure.net>2016-11-06 08:33:46 +0000
commit19599e55600bd19482b0a46c617caaa23e5ff46d (patch)
tree099ad5ab8f09a52e3d4f99469605beb98cfc5a73 /share/bash-completion/container
parentReadding container limit command. (diff)
downloadcompute-tools-19599e55600bd19482b0a46c617caaa23e5ff46d.tar.xz
compute-tools-19599e55600bd19482b0a46c617caaa23e5ff46d.zip
Readding container enter command.
Signed-off-by: Daniel Baumann <daniel.baumann@open-infrastructure.net>
Diffstat (limited to 'share/bash-completion/container')
-rw-r--r--share/bash-completion/container20
1 files changed, 20 insertions, 0 deletions
diff --git a/share/bash-completion/container b/share/bash-completion/container
index a283d5f..f6434f8 100644
--- a/share/bash-completion/container
+++ b/share/bash-completion/container
@@ -82,6 +82,26 @@ _container()
esac
;;
+ enter)
+ case "${cur}" in
+ -*)
+ opts="-n --name"
+ COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) )
+ return 0
+ ;;
+
+ *)
+ case "${prev}" in
+ -n|--name)
+ opts=$(container list -s -f short)
+ COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) )
+ return 0
+ ;;
+ esac
+ ;;
+ esac
+ ;;
+
limit)
case "${cur}" in
-*)