always set version to SNAPSHOT-{commit} for untagged CI builds

This commit is contained in:
Sebastian Stenzel
2019-11-12 13:23:05 +01:00
parent b2b6e304ed
commit 638b731cf8

View File

@@ -22,7 +22,7 @@ before_script:
- |
if [[ -n "$TRAVIS_TAG" ]]; then
mvn -fmain/pom.xml org.codehaus.mojo:versions-maven-plugin:set -DnewVersion=$TRAVIS_TAG
elif [[ $TRAVIS_BRANCH == "develop" ]] && [[ $TRAVIS_PULL_REQUEST == "false" ]]; then
else
mvn -fmain/pom.xml org.codehaus.mojo:versions-maven-plugin:set -DnewVersion=SNAPSHOT-$(echo $TRAVIS_COMMIT | head -c7)
fi
script: