8cf88f2b04668a425a5a4f470ad5f3c91dfea3eb

Author
Robby Russell <robby@planetargon.com>
Committer
Robby Russell <robby@planetargon.com>
Date

Message

Merge pull request #3911 from mbologna/git_remote_status_equal

added ZSH_THEME_GIT_PROMPT_EQUAL_REMOTE

Diff

 1diff --git a/lib/git.zsh b/lib/git.zsh
 2index caa7e632913251f9694b3a3b7cb357e2879e02cf..baf86371724d01ae842bbfe6d4f8e39530caf208 100644
 3--- a/lib/git.zsh
 4+++ b/lib/git.zsh
 5@@ -36,7 +36,10 @@ git_remote_status() {
 6         ahead=$(command git rev-list ${hook_com[branch]}@{upstream}..HEAD 2>/dev/null | wc -l)
 7         behind=$(command git rev-list HEAD..${hook_com[branch]}@{upstream} 2>/dev/null | wc -l)
 8 
 9-        if [ $ahead -gt 0 ] && [ $behind -eq 0 ]
10+        if [ $ahead -eq 0 ] && [ $behind -eq 0 ]
11+        then
12+          echo "$ZSH_THEME_GIT_PROMPT_EQUAL_REMOTE"
13+        elif [ $ahead -gt 0 ] && [ $behind -eq 0 ]
14         then
15             git_remote_status="$ZSH_THEME_GIT_PROMPT_AHEAD_REMOTE"
16             git_remote_status_detailed="$ZSH_THEME_GIT_PROMPT_AHEAD_REMOTE_COLOR$ZSH_THEME_GIT_PROMPT_AHEAD_REMOTE$((ahead))%{$reset_color%}"