Skip to content

Commit a0ba2bb

Browse files
committed
Merge branch 'mt/zsh-completion-optim'
Command line completion (incontrib/) update. * mt/zsh-completion-optim: completion: use native ZSH array pattern matching
2 parents e34df9a + a44a0a9 commit a0ba2bb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

contrib/completion/git-completion.bash

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -373,7 +373,7 @@ __gitcomp ()
373373
# Clear the variables caching builtins' options when (re-)sourcing
374374
# the completion script.
375375
if [[ -n ${ZSH_VERSION-} ]]; then
376-
unset $(set |sed -ne 's/^\(__gitcomp_builtin_[a-zA-Z0-9_][a-zA-Z0-9_]*\)=.*/\1/p') 2>/dev/null
376+
unset ${(M)${(k)parameters[@]}:#__gitcomp_builtin_*} 2>/dev/null
377377
else
378378
unset $(compgen -v __gitcomp_builtin_)
379379
fi

0 commit comments

Comments
 (0)