From 51726772ccf327f8dd2fccf4e2b4db6682056778 Mon Sep 17 00:00:00 2001 From: timkim Date: Mon, 30 Oct 2017 17:44:39 -0700 Subject: [PATCH] [#514] - make it easier to figure out if debug or release --- resources/circle-ci/android/aws-upload.sh | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) mode change 100644 => 100755 resources/circle-ci/android/aws-upload.sh diff --git a/resources/circle-ci/android/aws-upload.sh b/resources/circle-ci/android/aws-upload.sh old mode 100644 new mode 100755 index 688035411..1c437463f --- a/resources/circle-ci/android/aws-upload.sh +++ b/resources/circle-ci/android/aws-upload.sh @@ -5,10 +5,16 @@ if [ "$CIRCLECI" != true ]; then exit fi -if [ "$(git rev-parse HEAD)" != "$(git rev-parse $(git describe --abbrev=0 --tags))" ]; then - APKLOCATION=platforms/android/build/outputs/apk/android-debug.apk +debug="platforms/android/build/outputs/apk/android-debug.apk" +release="platforms/android/build/outputs/apk/android-release.apk" + +if [ -e "$debug" ]; then + APKLOCATION="$debug" +elif [ -e "$release" ]; then + APKLOCATION="$release" else - APKLOCATION=platforms/android/build/outputs/apk/android-release.apk + echo 'Error: Unable to find android apk file' + exit fi aws configure set aws_access_key_id $AWSACCESSKEY