From 20ed8d30306dc98d46a0a0b1d6d80c0a7d5e2545 Mon Sep 17 00:00:00 2001 From: Magesh Chandramouli Date: Wed, 2 Jan 2019 21:28:33 -0800 Subject: [PATCH] fixing deploy script --- .travis/deploy.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.travis/deploy.sh b/.travis/deploy.sh index 45bf51f..70c90d0 100755 --- a/.travis/deploy.sh +++ b/.travis/deploy.sh @@ -1,7 +1,7 @@ #!/bin/bash cd `dirname $0`/.. -if [ "${TRAVIS_BRANCH}" == 'master' -a "${TRAVIS_PULL_REQUEST}" == 'false' ]; then +if [ "${TRAVIS_BRANCH}" == 'master' -a "${TRAVIS_PULL_REQUEST}" == 'false' ] || [ -n "${TRAVIS_TAG}" ]; then if [[ -z "${SONATYPE_USERNAME}" || -z "${SONATYPE_PASSWORD}" ]]; then echo "ERROR! Please set SONATYPE_USERNAME and SONATYPE_PASSWORD environment variable" exit 1 @@ -21,6 +21,8 @@ if [ "${TRAVIS_BRANCH}" == 'master' -a "${TRAVIS_PULL_REQUEST}" == 'false' ]; th fi exit ${SUCCESS} +else + echo "Skipping artifact deployment for branch ${TRAVIS_BRANCH} with PR=${TRAVIS_PULL_REQUEST} and TAG=${TRAVIS_TAG}" fi exit 0