From 55fcfe7e8b3c47d2f9d97f41902f5ad56683b72c Mon Sep 17 00:00:00 2001 From: Harald Albers Date: Fri, 24 Feb 2017 13:27:32 +0100 Subject: [PATCH] Add completion for `--filter desired-state=shutdown` Signed-off-by: Harald Albers --- contrib/completion/bash/docker | 6 +++--- contrib/completion/zsh/_docker | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/contrib/completion/bash/docker b/contrib/completion/bash/docker index 7a1b12cd24..1c58d4e91e 100644 --- a/contrib/completion/bash/docker +++ b/contrib/completion/bash/docker @@ -2906,7 +2906,7 @@ _docker_service_ps() { local key=$(__docker_map_key_of_current_option '--filter|-f') case "$key" in desired-state) - COMPREPLY=( $( compgen -W "accepted running" -- "${cur##*=}" ) ) + COMPREPLY=( $( compgen -W "accepted running shutdown" -- "${cur##*=}" ) ) return ;; name) @@ -3391,7 +3391,7 @@ _docker_node_ps() { local key=$(__docker_map_key_of_current_option '--filter|-f') case "$key" in desired-state) - COMPREPLY=( $( compgen -W "accepted running" -- "${cur##*=}" ) ) + COMPREPLY=( $( compgen -W "accepted running shutdown" -- "${cur##*=}" ) ) return ;; name) @@ -3880,7 +3880,7 @@ _docker_stack_ps() { local key=$(__docker_map_key_of_current_option '--filter|-f') case "$key" in desired-state) - COMPREPLY=( $( compgen -W "accepted running" -- "${cur##*=}" ) ) + COMPREPLY=( $( compgen -W "accepted running shutdown" -- "${cur##*=}" ) ) return ;; id) diff --git a/contrib/completion/zsh/_docker b/contrib/completion/zsh/_docker index 20af1d0095..be33b6c961 100644 --- a/contrib/completion/zsh/_docker +++ b/contrib/completion/zsh/_docker @@ -1344,7 +1344,7 @@ __docker_node_complete_ps_filters() { if compset -P '*='; then case "${${words[-1]%=*}#*=}" in (desired-state) - state_opts=('accepted' 'running') + state_opts=('accepted' 'running' 'shutdown') _describe -t state-opts "desired state options" state_opts && ret=0 ;; *) @@ -1784,7 +1784,7 @@ __docker_service_complete_ps_filters() { if compset -P '*='; then case "${${words[-1]%=*}#*=}" in (desired-state) - state_opts=('accepted' 'running') + state_opts=('accepted' 'running' 'shutdown') _describe -t state-opts "desired state options" state_opts && ret=0 ;; *) @@ -2040,7 +2040,7 @@ __docker_stack_complete_ps_filters() { if compset -P '*='; then case "${${words[-1]%=*}#*=}" in (desired-state) - state_opts=('accepted' 'running') + state_opts=('accepted' 'running' 'shutdown') _describe -t state-opts "desired state options" state_opts && ret=0 ;; *)