aboutsummaryrefslogtreecommitdiff
path: root/completions/bash
diff options
context:
space:
mode:
authorzhangguanzhang <zhangguanzhang@qq.com>2020-09-17 21:16:39 +0800
committerzhangguanzhang <zhangguanzhang@qq.com>2020-09-17 21:40:03 +0800
commite18e4f4327358a999d61f0919239305480a92b62 (patch)
treea3301dc06bc851f08afac5b26ad399edb417fac1 /completions/bash
parent1a929c723669944e37e92932371154c6310d3251 (diff)
downloadpodman-e18e4f4327358a999d61f0919239305480a92b62.tar.gz
podman-e18e4f4327358a999d61f0919239305480a92b62.tar.bz2
podman-e18e4f4327358a999d61f0919239305480a92b62.zip
fix missing completion in podman run
Signed-off-by: zhangguanzhang <zhangguanzhang@qq.com>
Diffstat (limited to 'completions/bash')
-rw-r--r--completions/bash/podman12
1 files changed, 12 insertions, 0 deletions
diff --git a/completions/bash/podman b/completions/bash/podman
index 6cbad38d2..a83cfc790 100644
--- a/completions/bash/podman
+++ b/completions/bash/podman
@@ -404,6 +404,16 @@ __podman_local_interfaces() {
ip addr show scope global 2>/dev/null | sed -n 's| \+inet \([0-9.]\+\).* \([^ ]\+\)|\1 \2|p'
}
+__podman_complete_restart() {
+ case "$prev" in
+ --restart)
+ COMPREPLY=( $( compgen -W "always no on-failure" -- "$cur") )
+ return
+ ;;
+ esac
+ return 1
+}
+
__podman_complete_local_interfaces() {
local additional_interface
if [ "$1" = "--add" ] ; then
@@ -2178,6 +2188,7 @@ _podman_container_run() {
--preserve-fds
--publish -p
--pull
+ --restart
--runtime
--rootfs
--security-opt
@@ -2232,6 +2243,7 @@ _podman_container_run() {
--sig-proxy=false
"
__podman_complete_detach_keys && return
+ __podman_complete_restart && return
fi
case "$cur" in