diff --git a/.travis.yml b/.travis.yml index 5513db549..2bb2e6445 100644 --- a/.travis.yml +++ b/.travis.yml @@ -10,8 +10,10 @@ android: - android-sdk-license-.+ before_install: - yes | sdkmanager "platforms;android-27" # workaround for accepting the license -- openssl aes-256-cbc -K $encrypted_5ba4ee4c096f_key -iv $encrypted_5ba4ee4c096f_iv -in "$PWD/.travis/secrets.tar.enc" -out secrets.tar -d -- tar xf secrets.tar +- if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then + openssl aes-256-cbc -K $encrypted_5ba4ee4c096f_key -iv $encrypted_5ba4ee4c096f_iv -in "$PWD/.travis/secrets.tar.enc" -out secrets.tar -d; + tar xf secrets.tar; + fi - mkdir "$ANDROID_HOME/licenses" || true - echo -e "\n8933bad161af4178b1185d1a37fbf41ea5269c55" > "$ANDROID_HOME/licenses/android-sdk-license" - echo -e "\n84831b9409646a918e30573bab4c9c91346d8abd" > "$ANDROID_HOME/licenses/android-sdk-preview-license" diff --git a/.travis/build.sh b/.travis/build.sh index d1970c2db..58aecea0e 100755 --- a/.travis/build.sh +++ b/.travis/build.sh @@ -19,5 +19,5 @@ for APK in ${APKS[@]}; do APKDEST="$DEST/$APKNAME" ${TOOLS}/zipalign -v -p 4 $APK $APKDEST - ${TOOLS}/apksigner sign --ks $STORE_PATH --ks-key-alias $STORE_ALIAS --ks-pass env:STORE_PASS --key-pass env:KEY_PASS $APKDEST + [[ -z "$TRAVIS_PULL_REQUEST" ]] && ${TOOLS}/apksigner sign --ks $STORE_PATH --ks-key-alias $STORE_ALIAS --ks-pass env:STORE_PASS --key-pass env:KEY_PASS $APKDEST done