From d747f4dd04835d2b88957d57a22399aee163f97e Mon Sep 17 00:00:00 2001 From: Jonathan Steffan Date: Sat, 25 Jul 2026 13:49:22 -0600 Subject: [PATCH] fix(android): cache the gradle distribution and dependencies Every Android job downloads gradle-8.13-bin.zip and the whole Android plugin dependency tree from Maven Central on each run, so a Maven Central 403 fails the build before it configures anything: Could not GET '.../kotlin-stdlib-2.2.0.pom'. Received status code 403 from server: Forbidden Cache ~/.gradle/caches and ~/.gradle/wrapper, keyed on the wrapper properties and build.gradle. --- .github/workflows/APK-Release.yml | 9 +++++++++ .github/workflows/Build.yml | 9 +++++++++ 2 files changed, 18 insertions(+) diff --git a/.github/workflows/APK-Release.yml b/.github/workflows/APK-Release.yml index bf2ec47a..ffc7a338 100644 --- a/.github/workflows/APK-Release.yml +++ b/.github/workflows/APK-Release.yml @@ -25,6 +25,15 @@ jobs: ref: ${{ github.sha }} fetch-depth: 0 + # Gradle distribution and the Android plugin's dependencies. + - uses: actions/cache@v5 + with: + key: gradle-android-${{ hashFiles('gradle/wrapper/gradle-wrapper.properties', 'build.gradle') }} + path: | + ~/.gradle/caches + ~/.gradle/wrapper + restore-keys: gradle-android- + - name: Install dependencies run: | sudo apt-get update && sudo apt-get install glslang-tools spirv-tools librsvg2-bin gettext npm diff --git a/.github/workflows/Build.yml b/.github/workflows/Build.yml index af952c99..7e561ad1 100644 --- a/.github/workflows/Build.yml +++ b/.github/workflows/Build.yml @@ -196,6 +196,15 @@ jobs: ${{github.workspace}}/cmake-fetch/*.tgz restore-keys: cmake-android- + # Gradle distribution and the Android plugin's dependencies. + - uses: actions/cache@v5 + with: + key: gradle-android-${{ hashFiles('gradle/wrapper/gradle-wrapper.properties', 'build.gradle') }} + path: | + ~/.gradle/caches + ~/.gradle/wrapper + restore-keys: gradle-android- + - name: Install dependencies run: | sudo apt-get update && sudo apt-get install glslang-tools spirv-tools librsvg2-bin gettext