Skip to content

Commit 1d8c7fe

Browse files
build: update pipelines
1 parent 19ad30a commit 1d8c7fe

File tree

2 files changed

+38
-10
lines changed

2 files changed

+38
-10
lines changed

.github/workflows/base.yaml

Lines changed: 37 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16,23 +16,36 @@ jobs:
1616
runs-on: macos-latest
1717

1818
steps:
19-
- uses: actions/checkout@v4
19+
- name: Checkout repository
20+
uses: actions/checkout@v4
21+
with:
22+
fetch-depth: 1 # Use shallow clone for faster checkout
2023

2124
- name: Check broken links
2225
uses: JustinBeckwith/linkinator-action@v1
2326
with:
2427
paths: "**/*.md"
2528

2629
- name: Setup Java
27-
uses: actions/setup-java@v3
30+
uses: actions/setup-java@v4
2831
with:
2932
distribution: 'zulu'
3033
java-version: '11'
3134

35+
- name: Get Flutter version by FVM
36+
uses: kuhnroyal/flutter-fvm-config-action@v2
37+
id: fvm-config-action
38+
with:
39+
path: ".fvmrc"
40+
flavor: "stable"
41+
3242
- name: Flutter action
3343
uses: subosito/flutter-action@v2
3444
with:
35-
channel: 'stable'
45+
flutter-version: ${{ steps.fvm-config-action.outputs.FLUTTER_VERSION }}
46+
channel: ${{ steps.fvm-config-action.outputs.FLUTTER_CHANNEL }}
47+
architecture: x64
48+
cache: true
3649

3750
- name: Install dependencies
3851
run: flutter pub get
@@ -41,14 +54,16 @@ jobs:
4154
- name: Analyze static code
4255
run: flutter analyze
4356
- name: Run tests
44-
run: flutter test --coverage
57+
run: flutter test --no-pub --coverage
58+
- name: Check publish warnings
59+
run: dart pub publish --dry-run
4560
- name: Upload coverage to Codecov
46-
uses: codecov/codecov-action@v3
61+
uses: codecov/codecov-action@v4
62+
env:
63+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
4764
with:
4865
files: coverage/lcov.info
4966
name: form_builder_cupertino_fields
50-
- name: Check publish warnings
51-
run: dart pub publish --dry-run
5267
- name: Build example
5368
run: |
5469
cd example
@@ -65,10 +80,23 @@ jobs:
6580
runs-on: ubuntu-latest
6681
steps:
6782
- uses: actions/checkout@v4
83+
with:
84+
fetch-depth: 1 # Use shallow clone for faster checkout
6885
- uses: dart-lang/setup-dart@v1
69-
- name: Flutter action
86+
87+
- name: Get Flutter version by FVM
88+
uses: kuhnroyal/flutter-fvm-config-action@v2
89+
id: fvm-config-action
90+
with:
91+
path: ".fvmrc"
92+
flavor: "stable"
93+
94+
- name: Set up Flutter
7095
uses: subosito/flutter-action@v2
7196
with:
72-
channel: 'stable'
97+
flutter-version: ${{ steps.fvm-config-action.outputs.FLUTTER_VERSION }}
98+
channel: ${{ steps.fvm-config-action.outputs.FLUTTER_CHANNEL }}
99+
architecture: x64
100+
cache: true
73101
- name: Publish package
74102
run: dart pub publish -v -f

.github/workflows/stale.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ jobs:
77
stale:
88
runs-on: ubuntu-latest
99
steps:
10-
- uses: actions/stale@v8
10+
- uses: actions/stale@v9
1111
with:
1212
repo-token: ${{ secrets.GITHUB_TOKEN }}
1313
stale-issue-message: "This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days."

0 commit comments

Comments
 (0)