17
17
18
18
steps :
19
19
- uses : actions/checkout@v4
20
+ with :
21
+ fetch-depth : 1 # Use shallow clone for faster checkout
20
22
21
23
- name : Check broken links
22
24
uses : JustinBeckwith/linkinator-action@v1
@@ -29,10 +31,19 @@ jobs:
29
31
distribution : ' zulu'
30
32
java-version : ' 11'
31
33
34
+ - name : Get Flutter version by FVM
35
+ uses : kuhnroyal/flutter-fvm-config-action@v2
36
+ id : fvm-config-action
37
+ with :
38
+ path : " .fvmrc"
39
+
32
40
- name : Flutter action
33
41
uses : subosito/flutter-action@v2
34
42
with :
35
- channel : " stable"
43
+ flutter-version : ${{ steps.fvm-config-action.outputs.FLUTTER_VERSION }}
44
+ channel : ${{ steps.fvm-config-action.outputs.FLUTTER_CHANNEL }}
45
+ architecture : x64
46
+ cache : true
36
47
37
48
- name : Install dependencies
38
49
run : flutter pub get
41
52
- name : Analyze static code
42
53
run : flutter analyze
43
54
- name : Run tests
44
- run : flutter test --coverage
55
+ run : flutter test --no-pub -- coverage
45
56
- name : Upload coverage to Codecov
46
- uses : codecov/codecov-action@v3
57
+ uses : codecov/codecov-action@v4
58
+ env :
59
+ CODECOV_TOKEN : ${{ secrets.CODECOV_TOKEN }}
47
60
with :
48
61
files : coverage/lcov.info
49
62
name : form_builder_extra_fields
@@ -65,10 +78,22 @@ jobs:
65
78
runs-on : ubuntu-latest
66
79
steps :
67
80
- uses : actions/checkout@v4
81
+ with :
82
+ fetch-depth : 1 # Use shallow clone for faster checkout
68
83
- uses : dart-lang/setup-dart@v1
69
- - name : Flutter action
84
+
85
+ - name : Get Flutter version by FVM
86
+ uses : kuhnroyal/flutter-fvm-config-action@v2
87
+ id : fvm-config-action
88
+ with :
89
+ path : " .fvmrc"
90
+
91
+ - name : Set up Flutter
70
92
uses : subosito/flutter-action@v2
71
93
with :
72
- channel : " stable"
94
+ flutter-version : ${{ steps.fvm-config-action.outputs.FLUTTER_VERSION }}
95
+ channel : ${{ steps.fvm-config-action.outputs.FLUTTER_CHANNEL }}
96
+ architecture : x64
97
+ cache : true
73
98
- name : Publish package
74
99
run : dart pub publish -v -f
0 commit comments