kopia lustrzana https://github.com/meshtastic/Meshtastic-Android
Refactor: Update Gradle cache keys and task execution in CI (#2398)
Signed-off-by: James Rich <2199651+jamesarich@users.noreply.github.com>pull/2403/head^2
rodzic
a083af8d3f
commit
516739f5b0
|
|
@ -38,14 +38,14 @@ jobs:
|
|||
path: |
|
||||
~/.gradle/caches
|
||||
~/.gradle/wrapper
|
||||
key: gradle-${{ runner.os }}-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties', 'gradle.properties', 'settings.gradle*') }}
|
||||
key: gradle-${{ runner.os }}-${{ hashFiles('**/*.gradle.kts', '**/gradle.properties', '**/libs.versions.toml') }}
|
||||
restore-keys: |
|
||||
gradle-${{ runner.os }}-
|
||||
- name: Cache Android build cache
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: ~/.android/build-cache
|
||||
key: android-build-cache-${{ runner.os }}-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties', 'gradle.properties', 'settings.gradle*') }}
|
||||
key: android-build-cache-${{ runner.os }}-${{ hashFiles('**/*.gradle.kts', '**/gradle.properties', '**/libs.versions.toml') }}
|
||||
restore-keys: |
|
||||
android-build-cache-${{ runner.os }}-
|
||||
- name: Setup Gradle
|
||||
|
|
@ -67,8 +67,8 @@ jobs:
|
|||
echo "VERSION_CODE=$VERSION_CODE" >> $GITHUB_ENV
|
||||
|
||||
- name: Run Detekt, Build, Lint, and Local Tests
|
||||
run: ./gradlew detekt lintFdroidDebug lintGoogleDebug assembleDebug testFdroidDebug testGoogleDebug --configuration-cache --scan
|
||||
env:
|
||||
run: ./gradlew :app:detekt :app:lintFdroidDebug :app:lintGoogleDebug :app:assembleDebug :app:testFdroidDebug :app:testGoogleDebug --configuration-cache --scan
|
||||
env:
|
||||
VERSION_CODE: ${{ env.VERSION_CODE }}
|
||||
- name: Upload F-Droid debug artifact
|
||||
if: ${{ inputs.upload_artifacts }}
|
||||
|
|
@ -92,4 +92,4 @@ jobs:
|
|||
path: |
|
||||
app/build/reports
|
||||
**/build/reports/detekt
|
||||
retention-days: 14
|
||||
retention-days: 14
|
||||
|
|
@ -48,7 +48,7 @@ jobs:
|
|||
path: |
|
||||
~/.gradle/caches
|
||||
~/.gradle/wrapper
|
||||
key: gradle-${{ runner.os }}-${{ hashFiles('''**/*.gradle*''', '''**/gradle-wrapper.properties*''', '''gradle.properties*''', '''settings.gradle*''') }}
|
||||
key: gradle-${{ runner.os }}-${{ hashFiles('build.gradle.kts', 'settings.gradle.kts', 'gradle.properties', 'app/build.gradle.kts', 'buildSrc/build.gradle.kts') }}
|
||||
restore-keys: |
|
||||
gradle-${{ runner.os }}-
|
||||
- name: Setup Gradle
|
||||
|
|
@ -66,7 +66,7 @@ jobs:
|
|||
path: |
|
||||
~/.android/avd/*
|
||||
~/.android/adb*
|
||||
key: avd-${{ matrix.api-level }}-${{ hashFiles('''**/*.gradle*''', '''**/gradle-wrapper.properties*''') }}
|
||||
key: avd-${{ matrix.api-level }}-${{ hashFiles('build.gradle.kts', 'settings.gradle.kts', 'gradle.properties', 'app/build.gradle.kts', 'buildSrc/build.gradle.kts') }}
|
||||
restore-keys: |
|
||||
avd-${{ matrix.api-level }}-
|
||||
- name: Create AVD and generate snapshot for caching
|
||||
|
|
@ -96,4 +96,4 @@ jobs:
|
|||
with:
|
||||
name: android-test-reports-api-${{ matrix.api-level }}
|
||||
path: app/build/outputs/androidTest-results/
|
||||
retention-days: 14
|
||||
retention-days: 14
|
||||
Ładowanie…
Reference in New Issue