forked from eatvio/eatvio_app
Update .gitea/workflows/build.yml
This commit is contained in:
@@ -2,12 +2,21 @@ name: Android Release
|
||||
|
||||
on: [push, pull_request]
|
||||
|
||||
env:
|
||||
flutter_version: "3.19.0"
|
||||
java_version: "12.x"
|
||||
flutter_channel: "stable"
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: actions/cache@v2
|
||||
with:
|
||||
path: ${{ runner.tool_cache }}/flutter
|
||||
key: flutter-${{ env.flutter_version }}-${{ env.flutter_channel }}
|
||||
|
||||
- name: Install jq
|
||||
run: |
|
||||
@@ -23,13 +32,9 @@ jobs:
|
||||
- id: flutter-action
|
||||
uses: actions/flutter-action@v2
|
||||
with:
|
||||
channel: "stable"
|
||||
flutter-version: "3.19.0"
|
||||
channel: ${{ env.flutter_version }}
|
||||
flutter-version: ${{ env.flutter_channel }}
|
||||
cache: true
|
||||
cache-key: "flutter-:os:-:channel:-:version:-:arch:-:hash:" # optional, change this to force refresh cache
|
||||
cache-path: "${{ runner.tool_cache }}/flutter/:channel:-:version:-:arch:" # optional, change this to specify the cache path
|
||||
pub-cache-key: "flutter-pub:os:-:channel:-:version:-:arch:-:hash:" # optional, change this to force refresh cache of dart pub get dependencies
|
||||
pub-cache-path: "${{ runner.tool_cache }}/flutter/:channel:-:version:-:arch:" # optional, change this to specify the cache path
|
||||
|
||||
- name: show cache keys
|
||||
run: |
|
||||
@@ -50,8 +55,17 @@ jobs:
|
||||
- name: Get dependencies
|
||||
run: flutter pub get
|
||||
|
||||
- name: Native Analyze
|
||||
run: flutter analyze
|
||||
|
||||
- name: Run Code Metrics
|
||||
run: flutter pub run dart_code_metrics:metrics lib --disable-sunset-warning --fatal-warnings --fatal-performance
|
||||
|
||||
- name: Test
|
||||
run: |
|
||||
touch .env
|
||||
flutter test --coverage
|
||||
|
||||
# - name: Build apk
|
||||
# run: flutter build apk
|
||||
|
||||
|
||||
Reference in New Issue
Block a user