-
Notifications
You must be signed in to change notification settings - Fork 0
158 lines (149 loc) · 4.22 KB
/
Copy pathbuild-dotnet-dynamic.yml
File metadata and controls
158 lines (149 loc) · 4.22 KB
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
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
on:
workflow_call:
inputs:
disableCodeFormat:
required: false
type: boolean
default: false
disableCoverageUpload:
required: false
type: boolean
default: false
disableDependaMerge:
required: false
type: boolean
default: false
disableTestsOnLinux:
required: false
type: boolean
default: false
disableTestsOnMacOs:
required: false
type: boolean
default: true
disableTestsOnWindows:
required: false
type: boolean
default: true
dotnetLogging:
required: false
type: string
default: minimal
dotnetVersion:
required: false
type: string
default: |
8.x
9.x
enableCleanUpDockerDocker:
required: false
type: boolean
default: false
failFast:
required: false
type: boolean
default: true
runsOnBuild:
required: false
type: string
default: 'ubuntu-latest'
script-path:
required: true
type: string
solution:
required: true
type: string
clearDevCerts:
required: false
type: boolean
default: false
secrets:
FETCH_TOKEN:
required: false
concurrency:
group: ${{ github.workflow_ref }}@${{ github.ref }}-build-matrix-${{ inputs.solution }}
cancel-in-progress: true
env:
DOTNET_SYSTEM_GLOBALIZATION_INVARIANT: 1
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1
DOTNET_CLI_TELEMETRY_OPTOUT: 1
DOTNET_NOLOGO: true
permissions:
actions: read
contents: read
pull-requests: write
security-events: write
jobs:
commitlinter:
name: Commit Linter
uses: ./.github/workflows/step-node-commitlint.yml
secrets: inherit
version:
name: Version Management
uses: ./.github/workflows/step-dotnet-version.yml
with:
dotnet-version: ${{ inputs.dotnetVersion || '8.x' }}
secrets: inherit
collect:
name: Collect Dynamic Matrix
uses: ./.github/workflows/step-collect-matrix.yml
with:
script-path: ${{ inputs.script-path }}
secrets: inherit
format:
name: Code Formatting
if: ${{ !inputs.disableCodeFormat }}
uses: ./.github/workflows/step-dotnet-format.yml
needs:
- commitlinter
with:
dotnet-logging: ${{ inputs.dotnetLogging || 'minimal' }}
dotnet-version: ${{ inputs.dotnetVersion || '8.x' }}
runs-on: ${{ inputs.runsOnBuild || 'ubuntu-latest' }}
secrets: inherit
tests:
name: Run Tests
uses: ./.github/workflows/step-dotnet-tests.yml
needs:
- commitlinter
- version
- collect
strategy:
fail-fast: ${{ inputs.failFast }}
matrix:
test-filter: ${{ fromJson(needs.collect.outputs.matrix) }}
os:
- windows-latest
- ubuntu-latest
- macos-latest
exclude:
- os: ${{ inputs.disableTestsOnMacOs && 'macos-latest' }}
- os: ${{ inputs.disableTestsOnLinux && 'ubuntu-latest' }}
- os: ${{ inputs.disableTestsOnWindows && 'windows-latest' }}
with:
clear-dev-certs: ${{ inputs.clearDevCerts || false }}
disableCoverageUpload: ${{ inputs.disableCoverageUpload || false }}
dotnet-logging: ${{ inputs.dotnetLogging || 'minimal' }}
dotnet-version: ${{ inputs.dotnetVersion || '8.x' }}
enableCleanUpDockerDocker: ${{ inputs.enableCleanUpDockerDocker || false }}
execution-name: ${{ matrix.test-filter }}
runs-on: ${{ matrix.os }}
solution: ${{ inputs.solution }}
solution-version: ${{ needs.version.outputs.solution-version }}
test-filter: "/*/*/*/*[TestGroup=${{ matrix.test-filter }}]"
secrets: inherit
build:
name: Build Solution
if: ${{ !cancelled() && !failure() }}
uses: ./.github/workflows/step-dotnet-build.yml
needs:
- tests
- format
- version
with:
dotnet-logging: ${{ inputs.dotnetLogging || 'minimal' }}
dotnet-version: ${{ inputs.dotnetVersion || '8.x' }}
runs-on: ${{ inputs.runsOnBuild || 'ubuntu-latest' }}
solution: ${{ inputs.solution }}
solution-version: ${{ needs.version.outputs.solution-version }}
secrets: inherit