From fe3b439e31ce893d9345112e95a031aa5ec11183 Mon Sep 17 00:00:00 2001 From: Kevin Ballard Date: Wed, 26 Mar 2014 10:22:12 -0700 Subject: [PATCH] Fix non-verbose, non-informative __fish_git_prompt At some point the non-verbose, non-informative variant of the prompt (e.g. the variant that looks like the bash prompt) was modified to try and show the behind/ahead counts the same way the informative prompt does. Besides being wrong, it also didn't work because behind/ahead weren't defined. --- share/functions/__fish_git_prompt.fish | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/share/functions/__fish_git_prompt.fish b/share/functions/__fish_git_prompt.fish index 0619a0972..bc08871c5 100644 --- a/share/functions/__fish_git_prompt.fish +++ b/share/functions/__fish_git_prompt.fish @@ -336,11 +336,11 @@ function __fish_git_prompt_show_upstream --description "Helper function for __fi case "0 0" # equal to upstream echo "$___fish_git_prompt_char_upstream_prefix$___fish_git_prompt_char_upstream_equal" case "0 *" # ahead of upstream - echo "$___fish_git_prompt_char_upstream_prefix$___fish_git_prompt_char_upstream_ahead$ahead" + echo "$___fish_git_prompt_char_upstream_prefix$___fish_git_prompt_char_upstream_ahead" case "* 0" # behind upstream - echo "$___fish_git_prompt_char_upstream_prefix$___fish_git_prompt_char_upstream_behind$behind" + echo "$___fish_git_prompt_char_upstream_prefix$___fish_git_prompt_char_upstream_behind" case '*' # diverged from upstream - echo "$___fish_git_prompt_char_upstream_prefix$___fish_git_prompt_char_upstream_diverged$ahead-$behind" + echo "$___fish_git_prompt_char_upstream_prefix$___fish_git_prompt_char_upstream_diverged" end end end