mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-01-19 11:31:26 +01:00
Seth House: 28114: vcs_info, git: Fix revision lookup with packed repositories.
This commit is contained in:
parent
67e6e030d2
commit
01b4a67310
2 changed files with 7 additions and 6 deletions
|
@ -3,6 +3,10 @@
|
|||
* Seth House: 28115: Misc/vcs_info-examples: Another git example
|
||||
hook.
|
||||
|
||||
* Seth House: 28114:
|
||||
Functions/VCS_Info/Backends/VCS_INFO_get_data_git: Fix revision
|
||||
lookup with packed repositories.
|
||||
|
||||
2010-08-02 Peter Stephenson <pws@csr.com>
|
||||
|
||||
* Daiki Ueno: 28112: Src/Zle/zle_refresh.c: missing parentheses
|
||||
|
@ -13473,5 +13477,5 @@
|
|||
|
||||
*****************************************************
|
||||
* This is used by the shell to define $ZSH_PATCHLEVEL
|
||||
* $Revision: 1.5045 $
|
||||
* $Revision: 1.5046 $
|
||||
*****************************************************
|
||||
|
|
|
@ -101,11 +101,8 @@ VCS_INFO_git_getbranch () {
|
|||
|
||||
gitdir=${vcs_comm[gitdir]}
|
||||
gitbranch="$(VCS_INFO_git_getbranch ${gitdir})"
|
||||
if zstyle -t ":vcs_info:${vcs}:${usercontext}:${rrn}" get-revision && \
|
||||
[[ ${gitbranch} == refs/* ]] && \
|
||||
[[ -r "${gitdir}/${gitbranch}" ]] ; then
|
||||
|
||||
gitsha1="${"$(< $gitdir/$gitbranch)"}"
|
||||
if zstyle -t ":vcs_info:${vcs}:${usercontext}:${rrn}" get-revision ; then
|
||||
gitsha1=$(${vcs_comm[cmd]} rev-parse --quiet --verify HEAD)
|
||||
else
|
||||
gitsha1=''
|
||||
fi
|
||||
|
|
Loading…
Reference in a new issue