mirror of
https://github.com/moby/moby.git
synced 2026-01-11 18:51:37 +00:00
Make bash completion for docker stack deploy --bundle-file experimental
Signed-off-by: Harald Albers <github@albersweb.de>
(cherry picked from commit a53bdfa3be)
Signed-off-by: Victor Vieux <vieux@docker.com>
This commit is contained in:
committed by
Victor Vieux
parent
f68d703a8c
commit
dc05dfd30e
@@ -3514,8 +3514,10 @@ _docker_stack() {
|
||||
_docker_stack_deploy() {
|
||||
case "$prev" in
|
||||
--bundle-file)
|
||||
_filedir dab
|
||||
return
|
||||
if __docker_is_experimental ; then
|
||||
_filedir dab
|
||||
return
|
||||
fi
|
||||
;;
|
||||
--compose-file|-c)
|
||||
_filedir yml
|
||||
@@ -3525,7 +3527,9 @@ _docker_stack_deploy() {
|
||||
|
||||
case "$cur" in
|
||||
-*)
|
||||
COMPREPLY=( $( compgen -W "--bundle-file --compose-file -c --help --with-registry-auth" -- "$cur" ) )
|
||||
local options="--compose-file -c --help --with-registry-auth"
|
||||
__docker_is_experimental && options+=" --bundle-file"
|
||||
COMPREPLY=( $( compgen -W "$options" -- "$cur" ) )
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user