completions/*: Fix quoting around _omb_util_function_exists

This commit is contained in:
Koichi Murase
2022-08-23 16:17:42 +09:00
parent e0a4ada275
commit 49c66cf04a
5 changed files with 9 additions and 9 deletions

View File

@@ -133,7 +133,7 @@ _packer_completion ()
_omb_util_function_exists _get_comp_words_by_ref && _get_comp_words_by_ref -n = cur
COMPREPLY=()
local i c=1 command
local i c=1 command=
while [ $c -lt $COMP_CWORD ]; do
i="${COMP_WORDS[c]}"
@@ -144,7 +144,7 @@ _packer_completion ()
((c++))
done
if [ -z $command ]; then
if [ -z "$command" ]; then
case "$cur" in
'-'*)
__packercomp "-machine-readable --help --version"
@@ -157,7 +157,7 @@ _packer_completion ()
fi
local completion_func="__packer_${command}"
_omb_util_function_exists $completion_func && $completion_func
_omb_util_function_exists "$completion_func" && "$completion_func"
}
complete -o nospace -F _packer_completion packer