Make use of git dir determined by VCS_INFO subsystem

instead of determine the git dir manually.
pull/22/head
Dominik Ritter 6 years ago
parent 9a67ca5bc3
commit d07507c1eb

@ -104,7 +104,7 @@ function +vi-git-tagname() {
function +vi-git-stash() {
local -a stashes
if [[ -s $(command git rev-parse --git-dir)/refs/stash ]] ; then
if [[ -s "${vcs_comm[gitdir]}/refs/stash" ]] ; then
stashes=$(command git stash list 2>/dev/null | wc -l)
hook_com[misc]+=" $(print_icon 'VCS_STASH_ICON')${stashes// /}"
fi

Loading…
Cancel
Save