diff --git a/.github/workflows/flutter_project_codecheck_android.yml b/.github/workflows/flutter_project_codecheck_android.yml index f08d74b..02281c4 100644 --- a/.github/workflows/flutter_project_codecheck_android.yml +++ b/.github/workflows/flutter_project_codecheck_android.yml @@ -32,15 +32,24 @@ jobs: distribution: 'zulu' java-version: ${{ env.java_version }} - - name: '[Setup - Flutter Actions with Cache]' + - name: '[Setup - Cache Flutter and Pub Dependencies]' + uses: actions/cache@v4 + id: cache + with: + path: | + /home/runner/.pub-cache + /opt/hostedtoolcache/flutter + key: ${{ runner.os }}-flutter-${{ env.flutter_version }}-${{ hashFiles('pubspec.lock') }} + restore-keys: ${{ runner.os }}-flutter-${{ env.flutter_version }}- + + - name: '[Setup - Flutter SDK]' + if: steps.cache.outputs.cache-hit != 'true' uses: subosito/flutter-action@v2 with: channel: 'stable' flutter-version: ${{ env.flutter_version }} - cache: true + cache: false architecture: x64 - cache-key: 'flutter-:os:-:channel:-:version:-:arch:' - cache-path: '${{ runner.tool_cache }}/flutter/:channel:-:version:-:arch:' # Make sure we have latest FVM - name: '[FVM - Install]' @@ -72,8 +81,8 @@ jobs: run: fvm flutter analyze # Build is slightly faster when targeting single platform, debug version and only apk instead of appbundle - - name: '[Flutter - Build APK]' - run: fvm flutter build apk -t lib/main_staging.dart --flavor staging --target-platform android-arm64 --obfuscate --split-debug-info=build/app/outputs/symbols --debug + # - name: '[Flutter - Build APK]' + # run: fvm flutter build apk -t lib/main_staging.dart --flavor staging --target-platform android-arm64 --obfuscate --split-debug-info=build/app/outputs/symbols --debug # Only on self hosted. Cleanup the files after the build # - name: '[Finish - Cleanup]'