Skip to content

Commit 9e0ec12

Browse files
committed
Merge branch 'fc/completion-zsh' into maint
* fc/completion-zsh: git-completion: fix regression in zsh support
2 parents 5590fe7 + 52fd972 commit 9e0ec12

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

contrib/completion/git-completion.bash

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2710,6 +2710,10 @@ _git ()
27102710
if [[ -n ${ZSH_VERSION-} ]]; then
27112711
emulate -L bash
27122712
setopt KSH_TYPESET
2713+
2714+
# workaround zsh's bug that leaves 'words' as a special
2715+
# variable in versions < 4.3.12
2716+
typeset -h words
27132717
fi
27142718

27152719
local cur words cword
@@ -2761,6 +2765,10 @@ _gitk ()
27612765
if [[ -n ${ZSH_VERSION-} ]]; then
27622766
emulate -L bash
27632767
setopt KSH_TYPESET
2768+
2769+
# workaround zsh's bug that leaves 'words' as a special
2770+
# variable in versions < 4.3.12
2771+
typeset -h words
27642772
fi
27652773

27662774
__git_has_doubledash && return

0 commit comments

Comments
 (0)