summaryrefslogtreecommitdiff
path: root/functions/vcs.zsh
diff options
context:
space:
mode:
authorDominik Ritter <dritter03@googlemail.com>2018-11-03 05:11:51 +0300
committerDominik Ritter <dritter03@googlemail.com>2018-11-03 05:11:51 +0300
commitd07507c1ebf60d1d71ba491d0358b312e3e44807 (patch)
tree0c9de264bd0bb87f74dad7a60a976df00a6b3aa5 /functions/vcs.zsh
parent9a67ca5bc37a0dc6a397e59fb89b8565fcb468c4 (diff)
Make use of git dir determined by VCS_INFO subsystem
instead of determine the git dir manually.
Diffstat (limited to 'functions/vcs.zsh')
-rwxr-xr-xfunctions/vcs.zsh2
1 files changed, 1 insertions, 1 deletions
diff --git a/functions/vcs.zsh b/functions/vcs.zsh
index 23b2b661..cfc62a6d 100755
--- a/functions/vcs.zsh
+++ b/functions/vcs.zsh
@@ -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