Merge pull request #22046 from akka/wip-version-check-patriknw

prevent mistake of releasing from wrong branch (for validation)
This commit is contained in:
Patrik Nordwall 2016-12-21 14:24:18 +01:00 committed by GitHub
commit eeda6cc2c5

View file

@ -275,7 +275,11 @@ try ssh -t ${release_server} echo "Successfully contacted release server."
echolog "Getting current project version from sbt..." echolog "Getting current project version from sbt..."
declare -r current_version=$(get_current_version) declare -r current_version=$(get_current_version)
echolog "Current version is ${current_version}" echolog "Current version is ${current_version} on branch $initial_branch"
if [ "${current_version:0:3}" != "${version:0:3}" ]; then
fail "Releasing $version from wrong branch $initial_branch with version $current_version"
fi
# check out a release branch # check out a release branch
try git checkout -b ${release_branch} try git checkout -b ${release_branch}