Fix build determining current version
Only take the last line of the output. Current maven wrapper will output the current directy, later versions of the wrapper will output the wrapper version.
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
set -ev
|
||||
|
||||
VERSION=$(./mvnw -q -Dexec.executable="echo" -Dexec.args='${project.version}' --non-recursive org.codehaus.mojo:exec-maven-plugin:1.5.0:exec)
|
||||
VERSION=$(./mvnw -q -Dexec.executable="echo" -Dexec.args='${project.version}' --non-recursive org.codehaus.mojo:exec-maven-plugin:1.5.0:exec | tail -1)
|
||||
echo "Building PMD ${VERSION} on branch ${TRAVIS_BRANCH}"
|
||||
|
||||
if [[ "$VERSION" != *-SNAPSHOT && "$TRAVIS_TAG" != "" ]]; then
|
||||
|
@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
set -ev
|
||||
|
||||
RELEASE_VERSION=$(./mvnw -q -Dexec.executable="echo" -Dexec.args='${project.version}' --non-recursive org.codehaus.mojo:exec-maven-plugin:1.5.0:exec)
|
||||
RELEASE_VERSION=$(./mvnw -q -Dexec.executable="echo" -Dexec.args='${project.version}' --non-recursive org.codehaus.mojo:exec-maven-plugin:1.5.0:exec | tail -1)
|
||||
|
||||
# Deploy to ossrh has already been done with the usual build. See build-push.sh
|
||||
|
||||
|
Reference in New Issue
Block a user