mirror of
https://github.com/docker/cli.git
synced 2026-01-22 03:22:01 +03:00
Fix bash completion for `docker service create|update
Signed-off-by: Harald Albers <github@albersweb.de> Upstream-commit: be5685e4bffc88a6cd3a093ee883c5335758266d Component: engine
This commit is contained in:
@@ -2846,9 +2846,17 @@ _docker_service_update() {
|
||||
COMPREPLY=( $( compgen -W "$boolean_options $options_with_args" -- "$cur" ) )
|
||||
;;
|
||||
*)
|
||||
local counter=$( __docker_pos_first_nonflag $( __docker_to_alternatives "$options_with_args" ) )
|
||||
if [ "$subcommand" = "update" ] ; then
|
||||
__docker_complete_services
|
||||
if [ $cword -eq $counter ]; then
|
||||
__docker_complete_services
|
||||
fi
|
||||
else
|
||||
if [ $cword -eq $counter ]; then
|
||||
__docker_complete_images
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user