travis build - run only specific parts of release.sh script

This commit is contained in:
Andreas Dangel
2017-05-20 23:53:28 +02:00
parent 6aa77ce3e4
commit 23545aa7ea

View File

@ -2,11 +2,8 @@
set -e
echo "BUILD: $BUILD"
if [ "${BUILD}" != "deploy" ]; then
echo "Skipping deployment script, it needs to run only once"
exit 0
fi
if [ "${BUILD}" = "deploy" ]; then
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)
@ -46,8 +43,11 @@ else
echo "Update OK"
fi
fi
if [ "${BUILD}" = "site" ]; then
echo "Adding the site to pmd.github.io..."
# clone pmd.github.io. Note: This uses the ssh key setup earlier
# In order to speed things up, we use a sparse checkout - no need to checkout all directories here
@ -71,3 +71,5 @@ mkdir pmd.github.io
git push origin master
)
fi