Continuing the script when failing to check out... it happens for Jenkins for some reason

This commit is contained in:
Marcin Grzejszczak
2016-08-18 16:45:45 +02:00
parent fa67b987a3
commit 2a24b23f37

View File

@@ -208,7 +208,7 @@ function commit_changes_if_applicable() {
function checkout_previous_branch() {
# If -version was provided we need to come back to root project
cd ${ROOT_FOLDER}
git checkout ${CURRENT_BRANCH}
git checkout ${CURRENT_BRANCH} || echo "Failed to check the branch... continuing with the script"
if [ "$dirty" != "0" ]; then git stash pop; fi
exit 0
}