From be466c81c87dbd1736c366f9e5b49f2d83af8e6e Mon Sep 17 00:00:00 2001 From: flauschtrud Date: Wed, 3 Apr 2024 16:23:26 +0200 Subject: [PATCH] Specify build tools version, see https://github.com/r0adkll/sign-android-release/issues/84 --- .github/workflows/fdroid-release.yml | 9 +++++++++ .github/workflows/play-prerelease.yml | 9 +++++++++ 2 files changed, 18 insertions(+) diff --git a/.github/workflows/fdroid-release.yml b/.github/workflows/fdroid-release.yml index ffdc292b..3f1094b4 100644 --- a/.github/workflows/fdroid-release.yml +++ b/.github/workflows/fdroid-release.yml @@ -20,6 +20,13 @@ jobs: - name: Assemble Release run: ./gradlew clean assembleFdroidRelease + - name: Setup Build Tools Version + shell: bash + run: | + BUILD_TOOLS_VERSION=$(ls /usr/local/lib/android/sdk/build-tools/ | tail -n 1) + echo "BUILD_TOOLS_VERSION=$BUILD_TOOLS_VERSION" >> $GITHUB_ENV + echo Last build tools version is: $BUILD_TOOLS_VERSION + - name: Sign Release uses: r0adkll/sign-android-release@v1 id: sign_release @@ -29,6 +36,8 @@ jobs: alias: ${{ secrets.ALIAS }} keyStorePassword: ${{ secrets.KEY_STORE_PASSWORD }} keyPassword: ${{ secrets.KEY_PASSWORD }} + env: + BUILD_TOOLS_VERSION: ${{ env.BUILD_TOOLS_VERSION }} - name: Rename APK run: mv ${{steps.sign_release.outputs.signedReleaseFile}} app/build/outputs/apk/fdroid/release/app-fdroid-release.apk diff --git a/.github/workflows/play-prerelease.yml b/.github/workflows/play-prerelease.yml index d9fa1350..4e850e61 100644 --- a/.github/workflows/play-prerelease.yml +++ b/.github/workflows/play-prerelease.yml @@ -23,6 +23,13 @@ jobs: - name: Build Release Bundle with Gradle run: ./gradlew clean bundlePlay -Pbase64EncodedPublicKey=${{secrets.PUBLIC_KEY}} + - name: Setup Build Tools Version + shell: bash + run: | + BUILD_TOOLS_VERSION=$(ls /usr/local/lib/android/sdk/build-tools/ | tail -n 1) + echo "BUILD_TOOLS_VERSION=$BUILD_TOOLS_VERSION" >> $GITHUB_ENV + echo Last build tools version is: $BUILD_TOOLS_VERSION + - name: Build Release uses: r0adkll/sign-android-release@v1 with: @@ -31,6 +38,8 @@ jobs: alias: ${{ secrets.ALIAS }} keyStorePassword: ${{ secrets.KEY_STORE_PASSWORD }} keyPassword: ${{ secrets.KEY_PASSWORD }} + env: + BUILD_TOOLS_VERSION: ${{ env.BUILD_TOOLS_VERSION }} - name: Upload Android Release to Play Store uses: r0adkll/upload-google-play@v1.1.1