-
Notifications
You must be signed in to change notification settings - Fork 118
63 lines (59 loc) · 1.65 KB
/
validate.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: Validate
on: pull_request
jobs:
verify_commits:
runs-on: ubuntu-latest
steps:
- name: Conventional PRs
uses: Namchee/[email protected]
with:
access_token: ${{ secrets.GITHUB_TOKEN }}
link_issue: false
analyze:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: subosito/flutter-action@v2
with:
channel: beta
- name: Activate melos
run: |
echo "$HOME/.pub-cache/bin" >> $GITHUB_PATH
dart pub global activate melos
- name: Bootstrap melos
run: melos bs
- name: Analyze package
run: melos exec -- flutter analyze --no-fatal-infos
format:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/checkout@v3
- uses: subosito/flutter-action@v2
with:
channel: beta
- name: Activate melos
run: |
echo "$HOME/.pub-cache/bin" >> $GITHUB_PATH
dart pub global activate melos 2.9.0
- name: Bootstrap melos
run: melos bs
- name: Validate formatting
run: |
melos exec -- dart format -o write .
./.github/workflows/scripts/validate-formatting.sh
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: subosito/flutter-action@v2
with:
channel: beta
- name: Activate melos
run: |
echo "$HOME/.pub-cache/bin" >> $GITHUB_PATH
dart pub global activate melos 2.9.0
- name: Bootstrap melos
run: melos bs
- name: Run tests
run: melos exec --dir-exists=test -- flutter test