From a47ea35d4d872a389b792ecba9ebe05cae9b0243 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 28 Dec 2014 12:03:20 +0300 Subject: Add into pull and status script checking for diverged branches. --- pull.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'pull.sh') diff --git a/pull.sh b/pull.sh index 68c1f93..2362ae4 100755 --- a/pull.sh +++ b/pull.sh @@ -13,7 +13,7 @@ function status { return fi STR=$(git diff --name-only) - STR2=$(git status|grep "Your branch is ahead") + STR2=$(git status|grep "Your branch is ahead")$(git status|grep -E "have diverged") STR3=$(git status -s -uno) if [[ -n "${STR}${STR2}${STR3}" ]]; then echo -e "\e[1;31mCant pull because changes not pushed\e[0m" -- cgit v1.2.3-60-g2f50