1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-10-28 05:00:59 +01:00

30639: Add support for showing the current action is cherry-pick to vcs_info git backend

This commit is contained in:
Mikael Magnusson 2013-03-10 12:47:39 +00:00
parent ba88c42a5b
commit 0c8625299a
2 changed files with 16 additions and 1 deletions

View file

@ -7,6 +7,10 @@
* 30490: Completion/Unix/Command/_java: Complete files for the * 30490: Completion/Unix/Command/_java: Complete files for the
-keystore argument. -keystore argument.
* 30639: Functions/VCS_Info/Backends/VCS_INFO_get_data_git:
Add support for showing the current action is cherry-pick (happens
when cherry-picking a range).
2013-03-05 Peter Stephenson <p.w.stephenson@ntlworld.com> 2013-03-05 Peter Stephenson <p.w.stephenson@ntlworld.com>
* users/17666: Doc/Zsh/contrib.yo, Functions/Misc/zcalc: -f * users/17666: Doc/Zsh/contrib.yo, Functions/Misc/zcalc: -f
@ -570,5 +574,5 @@
***************************************************** *****************************************************
* This is used by the shell to define $ZSH_PATCHLEVEL * This is used by the shell to define $ZSH_PATCHLEVEL
* $Revision: 1.5814 $ * $Revision: 1.5815 $
***************************************************** *****************************************************

View file

@ -52,6 +52,17 @@ VCS_INFO_git_getaction () {
printf '%s' "bisect" printf '%s' "bisect"
return 0 return 0
fi fi
if [[ -f "${gitdir}/CHERRY_PICK_HEAD" ]] ; then
if [[ -d "${gitdir}/sequencer" ]] ; then
gitaction=cherry-seq
else
gitaction=cherry
fi
printf '%s' ${gitaction}
return 0
fi
return 1 return 1
} }