From 6fe246abe7c4b5ca791f3fe07f108ffc6d908d37 Mon Sep 17 00:00:00 2001 From: probonopd Date: Mon, 27 Feb 2017 16:48:21 +0100 Subject: [PATCH] if [ "${BINTRAY_API_KEY}" == "" ] ; then --- bintray.sh | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/bintray.sh b/bintray.sh index 3a2a330..982e9ee 100755 --- a/bintray.sh +++ b/bintray.sh @@ -11,7 +11,7 @@ FILE="$1" [ -f "$FILE" ] || { echo "File '$FILE' doesn't exist"; exit; } -if [ -z "$BINTRAY_API_KEY" ] ; then +if [ "${BINTRAY_API_KEY}" == "" ] ; then echo "BINTRAY_API_KEY is missing; assuming this is a PR, uploading to transfer.sh" curl --upload-file ./"$FILE" https://transfer.sh/$(basename "$FILE") exit 0 @@ -63,11 +63,6 @@ if [ ! -z "$TRAVIS_PULL_REQUEST" ] ; then fi fi -if [ -z "$BINTRAY_API_KEY" ] ; then - echo "Environment variable \$BINTRAY_API_KEY missing" - exit 1 -fi - CURL="curl -u${BINTRAY_USER}:${BINTRAY_API_KEY} -H Accept:application/json -w \n" set -x # Be verbose from here on