mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-09-04 22:51:42 +02:00
36722: allow git range to complete after ^.
Take account of backslash quoting.
This commit is contained in:
parent
8877783b2f
commit
9064483b6c
2 changed files with 13 additions and 1 deletions
|
@ -1,3 +1,8 @@
|
|||
2015-10-01 Peter Stephenson <p.stephenson@samsung.com>
|
||||
|
||||
* 36722: Completion/Unix/Command/_git: allow range to complete
|
||||
after ^, taking acoount of backslash quoting.
|
||||
|
||||
2015-10-01 Mikael Magnusson <mikachu@gmail.com>
|
||||
|
||||
* 36709: Doc/Zsh/zle.yo, Functions/Zle/bracketed-paste-url-magic,
|
||||
|
|
|
@ -5753,7 +5753,14 @@ __git_commit_ranges () {
|
|||
if compset -P '*..(.|)'; then
|
||||
expl=( $* )
|
||||
else
|
||||
compset -S '..*' || suf=( -S .. -r '.@~ ^:\t\n\-' )
|
||||
if ! compset -S '..*'; then
|
||||
local match mbegin mend
|
||||
if [[ ${PREFIX} = (#b)((\\|)\^)* ]]; then
|
||||
compset -p ${#match[1]}
|
||||
else
|
||||
suf=( -S .. -r '.@~ ^:\t\n\-' )
|
||||
fi
|
||||
fi
|
||||
expl=( $* $suf )
|
||||
fi
|
||||
|
||||
|
|
Loading…
Reference in a new issue