File tree Expand file tree Collapse file tree 1 file changed +3
-10
lines changed
Expand file tree Collapse file tree 1 file changed +3
-10
lines changed Original file line number Diff line number Diff line change 11#! /bin/bash
22cd ` dirname $0 ` /..
33
4- function fix_git {
5- echo " Fixing git setup for $TRAVIS_BRANCH "
6- git checkout ${TRAVIS_BRANCH}
7- git branch -u origin/${TRAVIS_BRANCH}
8- git config branch.${TRAVIS_BRANCH} .remote origin
9- git config branch.${TRAVIS_BRANCH} .merge refs/heads/${TRAVIS_BRANCH}
10- }
11-
12-
134if [ " ${TRAVIS_BRANCH} " == ' master' -a " ${TRAVIS_PULL_REQUEST} " == ' false' ] || [ -n " ${TRAVIS_TAG} " ]; then
145 if [[ -z " ${SONATYPE_USERNAME} " || -z " ${SONATYPE_PASSWORD} " ]]; then
156 echo " ERROR! Please set SONATYPE_USERNAME and SONATYPE_PASSWORD environment variable"
167 exit 1
178 fi
189
10+ TAG_NAME=` git describe ${TRAVIS_COMMIT} --tags`
11+ echo " Tag associated with the current commit ${TRAVIS_COMMIT} is ${TAG_NAME} "
12+
1913 if [ ! -z " ${TRAVIS_TAG} " ]; then
20- fix_git
2114 echo " travis tag is set -> updating pom.xml <version> attribute to ${TRAVIS_TAG} "
2215 ./mvnw --batch-mode --settings .travis/settings.xml -DskipTests=true -DreleaseVersion=${TRAVIS_TAG} release:clean release:prepare release:perform
2316 SUCCESS=$?
You can’t perform that action at this time.
0 commit comments