-
Notifications
You must be signed in to change notification settings - Fork 246
57 lines (48 loc) · 1.33 KB
/
build.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
name: "build and test"
on:
push:
branches: ["main"]
paths:
- 'src/**'
pull_request:
branches: ["main"]
paths:
- 'src/**'
- '.github/workflows/build.yml'
permissions:
actions: write
jobs:
analyze:
name: build
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: '7.x'
- name: Install GitVersion
uses: gittools/actions/gitversion/setup@v0
with:
versionSpec: '5.x'
preferLatestVersion: true
- name: Determine version
uses: gittools/actions/gitversion/execute@v0
with:
updateAssemblyInfo: true
useConfigFile: true
configFilePath: gitversion.yml
- name: Build solution
run: dotnet build >
--configuration Release
/p:Version=${{env.nuGetVersion}}
/p:ContinuousIntegrationBuild=true
/warnaserror
- name: Test library
run: dotnet test >
tests/indicators/Tests.Indicators.csproj
--configuration Release
--no-restore
--no-build
--collect:"XPlat Code Coverage" -- DataCollectionRunSettings.DataCollectors.DataCollector.Configuration.Format=cobertura