From f5eb62c1801cc099c31eb5b3d1b6c6e6941c4d8e Mon Sep 17 00:00:00 2001 From: Harald Albers Date: Wed, 16 Sep 2015 18:09:35 +0200 Subject: [PATCH] Fix bash completion when extglob is not set Signed-off-by: Harald Albers --- contrib/completion/bash/docker | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/contrib/completion/bash/docker b/contrib/completion/bash/docker index 9d63416c4b..be229039d3 100644 --- a/contrib/completion/bash/docker +++ b/contrib/completion/bash/docker @@ -182,12 +182,12 @@ __docker_pos_first_nonflag() { # globs like '--log-level|-l' # Only positions between the command and the current word are considered. __docker_value_of_option() { - local option_glob=$1 + local option_extglob=$(__docker_to_extglob "$1") local counter=$((command_pos + 1)) while [ $counter -lt $cword ]; do case ${words[$counter]} in - @($option_glob) ) + $option_extglob ) echo ${words[$counter + 1]} break ;;