1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-09-29 19:00:57 +02:00

unposted: _git: Fix 'commit object name' completion messages.

Offer the "this alternative is still valid, but I don't know to offer
completions for it" for hash completion but not for recent object completion;
the former is protected by a _guard and the latter incorrectly appeared also in
cases such as 'git log a/b<TAB>' which were not the start of a gitrevisions(7)
expression.
This commit is contained in:
Daniel Shahaf 2015-10-25 18:39:31 +00:00
parent a40417929c
commit f8b2c13c97
2 changed files with 7 additions and 2 deletions

View file

@ -1,3 +1,8 @@
2015-10-25 Daniel Shahaf <d.s@daniel.shahaf.name>
* unposted: Completion/Unix/Command/_git: _git: Fix 'commit
object name' completion messages.
2015-10-25 Jun-ichi Takimoto <takimoto-j@kba.biglobe.ne.jp>
* 36911: Src/Zle/computil.c: '-optarg' should not match

View file

@ -5640,7 +5640,7 @@ __git_commit_objects () {
commits=(${(f)"$(_call_program commits git --no-pager log -1000 --all --reflog --format='%h:\[%h\]\ %s\ \(%cr\)')"})
__git_command_successful $pipestatus || return 1
_describe -V -t commits 'commit object name' commits
_describe -Vx -t commits 'commit object name' commits
}
(( $+functions[__git_recent_commits] )) ||
@ -5704,7 +5704,7 @@ __git_recent_commits () {
expl=()
_wanted heads expl 'head' compadd "$@" -a - heads && ret=0
expl=()
_describe -Vx -t commits 'recent commit object name' descr && ret=0
_describe -V -t commits 'recent commit object name' descr && ret=0
return $ret
}