From e5e28021bf4fafb3d41739d6647294ace7e34cbc Mon Sep 17 00:00:00 2001 From: axi92 Date: Mon, 26 Aug 2024 14:34:30 +0200 Subject: [PATCH 1/4] build: removed unused variables for android build --- .github/workflows/android.yml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.github/workflows/android.yml b/.github/workflows/android.yml index 06ea4f0..6e417eb 100644 --- a/.github/workflows/android.yml +++ b/.github/workflows/android.yml @@ -29,7 +29,3 @@ jobs: - name: Build android example app run: yarn build:android - env: - GH_USERNAME: ${{ vars.USERNAME }} - # PAT has read:packages permissions - GH_TOKEN: ${{ secrets.TOKEN }} From ee156d64f2c309c0dddd86110e625966ed1f8ddc Mon Sep 17 00:00:00 2001 From: axi92 Date: Mon, 26 Aug 2024 14:34:51 +0200 Subject: [PATCH 2/4] build: enable gradle cache --- .github/workflows/android.yml | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/.github/workflows/android.yml b/.github/workflows/android.yml index 6e417eb..a3786ee 100644 --- a/.github/workflows/android.yml +++ b/.github/workflows/android.yml @@ -23,9 +23,19 @@ jobs: uses: actions/setup-node@v4 with: node-version: '22' + cache: 'yarn' - run: | - corepack yarn + which corepack + corepack enable cd example && yarn install + - name: Cache Gradle + uses: actions/cache@v4 + with: + path: | + .gradle + example/android/.gradle + key: gradle + - name: Build android example app run: yarn build:android From 2b3a817cfc55dea522f63204c8447be1aa8faf79 Mon Sep 17 00:00:00 2001 From: axi92 Date: Mon, 26 Aug 2024 14:54:05 +0200 Subject: [PATCH 3/4] build: add ~/.gradle/caches to build cache for android --- .github/workflows/android.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/android.yml b/.github/workflows/android.yml index a3786ee..3cbadf3 100644 --- a/.github/workflows/android.yml +++ b/.github/workflows/android.yml @@ -25,7 +25,6 @@ jobs: node-version: '22' cache: 'yarn' - run: | - which corepack corepack enable cd example && yarn install @@ -35,6 +34,7 @@ jobs: path: | .gradle example/android/.gradle + ~/.gradle/caches key: gradle - name: Build android example app From 252e28e882615164ae85f42be3e5a5c41439f5e9 Mon Sep 17 00:00:00 2001 From: axi92 Date: Mon, 26 Aug 2024 15:04:50 +0200 Subject: [PATCH 4/4] build: use same cache in test and build workflow for gradle --- .github/workflows/test.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 49a46c2..1bdd74d 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -96,18 +96,19 @@ jobs: example/node_modules key: cache-test-node-modules - name: Cache Gradle - id: cache-test-android-gradle + id: cache_gradle uses: actions/cache@v4 with: path: | .gradle example/android/.gradle - key: ${{ runner.os }}_cache-test-android-gradle + ~/.gradle/caches + key: gradle - run: | corepack enable yarn - name: Run Gradle - if: steps.cache-test-android-gradle.outputs.cache-hit != 'true' + if: steps.cache_gradle.outputs.cache-hit != 'true' run: example/android/gradlew - name: Run Tests run: make test-android