From 1d1e8a54a0bf8c8bc250233a73e9ef2b3a8cbae6 Mon Sep 17 00:00:00 2001 From: Henrik Hermansen Date: Wed, 13 Jan 2021 13:10:21 +0100 Subject: [PATCH] Properly fix git diff check --- share/tools/web_config/sample_prompts/acidhub.fish | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/tools/web_config/sample_prompts/acidhub.fish b/share/tools/web_config/sample_prompts/acidhub.fish index 8cdec14fc..0adb527d5 100644 --- a/share/tools/web_config/sample_prompts/acidhub.fish +++ b/share/tools/web_config/sample_prompts/acidhub.fish @@ -8,7 +8,7 @@ function fish_prompt -d "Write out the prompt" if set -l git_branch (command git symbolic-ref HEAD 2>/dev/null | string replace refs/heads/ '') set git_branch (set_color -o blue)"$git_branch" set -l git_status - if command git diff-index HEAD -- --quiet + if not command git diff-index --quiet HEAD -- if set -l count (command git rev-list --count --left-right $upstream...HEAD 2>/dev/null) echo $count | read -l ahead behind if test "$ahead" -gt 0