Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: enable android build cache #39

Merged
merged 6 commits into from
Aug 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 11 additions & 5 deletions .github/workflows/android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,19 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'yarn'
- run: |
corepack yarn
corepack enable
cd example && yarn install

- name: Cache Gradle
uses: actions/cache@v4
with:
path: |
.gradle
example/android/.gradle
~/.gradle/caches
key: gradle

- name: Build android example app
run: yarn build:android
env:
GH_USERNAME: ${{ vars.USERNAME }}
# PAT has read:packages permissions
GH_TOKEN: ${{ secrets.TOKEN }}
7 changes: 4 additions & 3 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Loading