summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-x.ci/scripts/android/build.sh9
-rwxr-xr-x.ci/scripts/android/upload.sh12
2 files changed, 9 insertions, 12 deletions
diff --git a/.ci/scripts/android/build.sh b/.ci/scripts/android/build.sh
index a5fd1ee18..d135af029 100755
--- a/.ci/scripts/android/build.sh
+++ b/.ci/scripts/android/build.sh
@@ -8,8 +8,17 @@ ccache -s
BUILD_FLAVOR=mainline
+if [ ! -z "${ANDROID_KEYSTORE_B64}" ]; then
+ export ANDROID_KEYSTORE_FILE="${GITHUB_WORKSPACE}/ks.jks"
+ base64 --decode <<< "${ANDROID_KEYSTORE_B64}" > "${ANDROID_KEYSTORE_FILE}"
+fi
+
cd src/android
chmod +x ./gradlew
./gradlew "assemble${BUILD_FLAVOR}Release" "bundle${BUILD_FLAVOR}Release"
ccache -s
+
+if [ ! -z "${ANDROID_KEYSTORE_B64}" ]; then
+ rm "${ANDROID_KEYSTORE_FILE}"
+fi
diff --git a/.ci/scripts/android/upload.sh b/.ci/scripts/android/upload.sh
index cfaeff328..5f8ca73c0 100755
--- a/.ci/scripts/android/upload.sh
+++ b/.ci/scripts/android/upload.sh
@@ -13,15 +13,3 @@ cp src/android/app/build/outputs/apk/"${BUILD_FLAVOR}/release/app-${BUILD_FLAVOR
"artifacts/${REV_NAME}.apk"
cp src/android/app/build/outputs/bundle/"${BUILD_FLAVOR}Release"/"app-${BUILD_FLAVOR}-release.aab" \
"artifacts/${REV_NAME}.aab"
-
-if [ -n "${ANDROID_KEYSTORE_B64}" ]
-then
- echo "Signing apk..."
- base64 --decode <<< "${ANDROID_KEYSTORE_B64}" > ks.jks
-
- apksigner sign --ks ks.jks \
- --ks-key-alias "${ANDROID_KEY_ALIAS}" \
- --ks-pass env:ANDROID_KEYSTORE_PASS "artifacts/${REV_NAME}.apk"
-else
- echo "No keystore specified, not signing the APK files."
-fi