From f1047bcd6f1b7afa03e9e17c37bb96ea07ab569c Mon Sep 17 00:00:00 2001 From: MohitMaliFtechiz Date: Thu, 28 Nov 2024 12:15:30 +0530 Subject: [PATCH] Generated dummy release APKs along with the dummy bundle to have them readily available if needed. * For example, in the current scenario, we need to manually generate the release APKs and upload them to the 3.12.0 GitHub release so that IzzyOnDroid can fetch and update the application on their platform. --- ...my_bundle.yml => dummy_bundle_and_apk.yml} | 21 ++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) rename .github/workflows/{dummy_bundle.yml => dummy_bundle_and_apk.yml} (68%) diff --git a/.github/workflows/dummy_bundle.yml b/.github/workflows/dummy_bundle_and_apk.yml similarity index 68% rename from .github/workflows/dummy_bundle.yml rename to .github/workflows/dummy_bundle_and_apk.yml index bd946537c..05648a929 100644 --- a/.github/workflows/dummy_bundle.yml +++ b/.github/workflows/dummy_bundle_and_apk.yml @@ -1,4 +1,4 @@ -name: Generate dummy bundle +name: Generate dummy bundle and APK # The workflow will trigger when the `dummy_bundle` tag is pushed. on: @@ -7,7 +7,7 @@ on: - 'dummy_bundle' # dummy_bundle Tag jobs: - publish_dummy_bundle: + publish_dummy_bundle_and_apk: runs-on: ubuntu-22.04 steps: @@ -25,22 +25,23 @@ jobs: run: | echo "$KEYSTORE" | base64 -d > kiwix-android.keystore - - name: Generate dummy Bundle + - name: Generate dummy Bundle and APKs env: KEY_ALIAS: ${{ secrets.KEY_ALIAS }} KEY_PASSWORD: ${{ secrets.KEY_PASSWORD }} KEY_STORE_PASSWORD: ${{ secrets.KEY_STORE_PASSWORD }} run: | - ./gradlew bundlePlayStore --scan + ./gradlew bundlePlayStore assembleRelease --scan - - - name: Get Bundle name and path - id: bundle-path + - name: Get Bundle and APKs name and path + id: get-bundle-and-apk-paths run: | BUNDLE_PATH="app/build/outputs/bundle/playStore/kiwix-playStore.aab" BUNDLE_NAME="PlayStoreDummyBundle.aab" echo "bundle_path=$BUNDLE_PATH" >> $GITHUB_ENV echo "bundle_name=$BUNDLE_NAME" >> $GITHUB_ENV + APK_DIR="app/build/outputs/apk/release/" + echo "apk_dir=$APK_DIR" >> $GITHUB_ENV - name: Upload Bundle as an artifact uses: actions/upload-artifact@v4 @@ -48,3 +49,9 @@ jobs: name: ${{ env.bundle_name }} path: ${{ env.bundle_path }} + - name: Upload All Release APKs as artifacts + uses: actions/upload-artifact@v4 + with: + name: ReleaseApks + path: ${{ env.apk_dir }}*.apk +