From 3621b5a67c3ea87d47e8679c4a12117d09d23125 Mon Sep 17 00:00:00 2001 From: oGre Date: Fri, 25 Sep 2015 19:41:07 +0200 Subject: [PATCH] We set branch first, then remote --- gitstatus.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/gitstatus.sh b/gitstatus.sh index 7782e62..e01e00d 100755 --- a/gitstatus.sh +++ b/gitstatus.sh @@ -51,10 +51,9 @@ if (( num_changed == 0 && num_staged == 0 && num_untracked == 0 && num_stashed = clean=1 fi -remote= - IFS="." read -ra line <<< "${branch_line/\#\# }" branch="${line[0]}" +remote= if [[ "$branch" == *"Initial commit on"* ]]; then IFS=" " read -ra branch_line <<< "$branch"