2.3.0 #1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Android CI | |
on: | |
push: | |
branches: [ master ] | |
paths-ignore: | |
- "**.md" | |
pull_request: | |
branches: [ master ] | |
jobs: | |
ci-build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
submodules: 'recursive' | |
- name: Validate Gradle wrapper | |
uses: gradle/wrapper-validation-action@v2 | |
- name: Mock files for CI | |
run: | | |
rm ./app/google-services.json | |
cp ./app/google-services-example.json ./app/google-services.json | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v4 | |
with: | |
java-version: '17' | |
distribution: 'zulu' | |
- name: Setup Gradle | |
uses: gradle/gradle-build-action@v3 | |
- name: Check lint | |
run: ./gradlew lintFdroidDebug lintGoogleDebug | |
- name: Build debug artifacts | |
run: ./gradlew assembleDebug | |
- name: Run local tests | |
run: ./gradlew testFdroidDebug testGoogleDebug | |
- name: Upload debug artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: fdroidDebug | |
path: app/build/outputs/apk/fdroid/debug/app-fdroid-debug.apk | |
retention-days: 30 | |
- name: Upload build reports | |
if: always() | |
uses: actions/upload-artifact@v4 | |
with: | |
name: build-reports | |
path: app/build/reports | |
retention-days: 30 |