-
Notifications
You must be signed in to change notification settings - Fork 23
97 lines (81 loc) · 2.58 KB
/
dart_ci.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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
name: Dart CI
on:
push:
branches:
- 'master'
- 'test_consume_*'
pull_request:
branches:
- '**'
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
sdk: [ 2.19.6, stable ]
steps:
- uses: actions/checkout@v2
- uses: dart-lang/setup-dart@v1
with:
sdk: ${{ matrix.sdk }}
- id: install
name: Install dependencies
working-directory: ./w_common
run: dart pub get
- name: Validate dependencies
working-directory: ./w_common
run: dart run dependency_validator
if: always() && steps.install.outcome == 'success'
- name: Analyze project source
working-directory: ./w_common
run: dart analyze
if: always() && steps.install.outcome == 'success'
- name: Run tests
working-directory: ./w_common
run: dart test
if: always() && steps.install.outcome == 'success'
- id: install-tools
name: Install w_common_tools dependencies
working-directory: ./w_common_tools
run: dart pub get
- name: Validate w_common_tools dependencies
working-directory: ./w_common_tools
run: dart run dependency_validator
if: always() && steps.install-tools.outcome == 'success'
- name: Analyze w_common_tools source
working-directory: ./w_common_tools
run: dart analyze
if: always() && steps.install-tools.outcome == 'success'
- name: Run w_common_tools tests
working-directory: ./w_common_tools
run: dart test
if: always() && steps.install-tools.outcome == 'success'
- uses: anchore/sbom-action@v0
if: ${{ matrix.sdk == '2.19.6'}}
with:
path: ./
format: cyclonedx-json
format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: dart-lang/[email protected]
with:
sdk: 2.19.6
- id: install
name: Install dependencies
working-directory: ./w_common
run: dart pub get
- name: Verify formatting
working-directory: ./w_common
run: dart format --output=none --set-exit-if-changed .
if: always() && steps.install.outcome == 'success'
- id: install-tools
name: Install dependencies
working-directory: ./w_common_tools
run: dart pub get
- name: Verify formatting
run: dart format --output=none --set-exit-if-changed .
working-directory: ./w_common_tools
if: always() && steps.install-tools.outcome == 'success'