diff --git a/lib/git.zsh b/lib/git.zsh index 7bc85819b..c79cc0d8e 100644 --- a/lib/git.zsh +++ b/lib/git.zsh @@ -86,7 +86,7 @@ function git_commits_ahead() { # Gets the number of commits behind remote function git_commits_behind() { if $(command git rev-parse --git-dir > /dev/null 2>&1); then - echo $(git rev-list --count $(current_branch)..$(git rev-parse --abbrev-ref --symbolic-full-name @{u})) + echo $(git rev-list --count HEAD..@{upstream}) fi }