diff --git a/docker/PYROS_DOCKER_UPDATE b/docker/PYROS_DOCKER_UPDATE index 2c0b9cd..b297d4f 100755 --- a/docker/PYROS_DOCKER_UPDATE +++ b/docker/PYROS_DOCKER_UPDATE @@ -14,6 +14,14 @@ fi echo "Updating Guitastro source code" cd ../vendor/guitastro/ gitpull_output=$(git pull 2>&1) +already_uptodate="Déjà à jour." +if [ $? -eq 1 ]; then + if [[ "$gitpull_output"!="$already_uptodate" ]]; then + echo "Git pull failed. Error message is:" + echo $gitpull_output + exit 1 + fi +fi echo $gitpull_output check_files=("docker-compose.yml" "Dockerfile" "install/requirements.in") for file in "${check_files[@]}" @@ -28,6 +36,13 @@ done cd $root_folder echo "Updating PyROS source code" gitpull_output=$(git pull 2>&1) +if [ $? -eq 1 ]; then + if [[ "$gitpull_output"!="$already_uptodate" ]]; then + echo "Git pull failed. Error message is:" + echo $gitpull_output + exit 1 + fi +fi echo $gitpull_output check_files=("docker-compose.yml" "Dockerfile" "install/requirements.in") for file in "${check_files[@]}" -- libgit2 0.21.2