diff options
author | Junio C Hamano <gitster@pobox.com> | 2013-03-07 13:11:55 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-03-07 13:11:55 -0800 |
commit | c5443b2a1ee34f2a9adc1bfa0b2d232567e16fa7 (patch) | |
tree | 95a760546137b1a46d5657a0882ca3dfdc281b63 /contrib/completion/git-completion.zsh | |
parent | Merge branch 'maint' (diff) | |
parent | git-completion.zsh: define __gitcomp_file compatibility function (diff) | |
download | tgif-c5443b2a1ee34f2a9adc1bfa0b2d232567e16fa7.tar.xz |
Merge branch 'mp/complete-paths'
* mp/complete-paths:
git-completion.zsh: define __gitcomp_file compatibility function
Diffstat (limited to 'contrib/completion/git-completion.zsh')
-rw-r--r-- | contrib/completion/git-completion.zsh | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/contrib/completion/git-completion.zsh b/contrib/completion/git-completion.zsh index 45775021ff..cf8116d477 100644 --- a/contrib/completion/git-completion.zsh +++ b/contrib/completion/git-completion.zsh @@ -60,6 +60,15 @@ __gitcomp_nl () compadd -Q -S "${4- }" -p "${2-}" -- ${=1} && _ret=0 } +__gitcomp_file () +{ + emulate -L zsh + + local IFS=$'\n' + compset -P '*[=:]' + compadd -Q -p "${2-}" -f -- ${=1} && _ret=0 +} + _git () { local _ret=1 |