Skip to content

Commit

Permalink
Merge pull request #7669 from zhangguanzhang/missing-completion
Browse files Browse the repository at this point in the history
fix missing completion in podman run
  • Loading branch information
openshift-merge-robot authored Sep 17, 2020
2 parents 031ddf9 + e18e4f4 commit cedbb05
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions completions/bash/podman
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down Expand Up @@ -2178,6 +2188,7 @@ _podman_container_run() {
--preserve-fds
--publish -p
--pull
--restart
--runtime
--rootfs
--security-opt
Expand Down Expand Up @@ -2232,6 +2243,7 @@ _podman_container_run() {
--sig-proxy=false
"
__podman_complete_detach_keys && return
__podman_complete_restart && return
fi

case "$cur" in
Expand Down

0 comments on commit cedbb05

Please sign in to comment.