d&c: looks like git status is not the same everywhere so use another trick
This commit is contained in:
parent
0e925e2b65
commit
82931efe42
1 changed files with 2 additions and 2 deletions
|
@ -91,8 +91,8 @@ function _gitUpdate(){
|
||||||
fi
|
fi
|
||||||
branch=$1
|
branch=$1
|
||||||
set +e
|
set +e
|
||||||
git status | grep -q "nothing to commit, working directory clean"; result=$?
|
git diff --exit-code 2>&1 > /dev/null
|
||||||
if [ $result != 1 ]; then
|
if [ $? != 1 ]; then
|
||||||
set -e
|
set -e
|
||||||
git checkout -f $branch
|
git checkout -f $branch
|
||||||
git pull -r
|
git pull -r
|
||||||
|
|
Loading…
Reference in a new issue