-
-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (48 loc) · 1.35 KB
/
dotnet.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
name: .NET
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore
- name: Test
run: dotnet test --no-build --verbosity normal --collect:"XPlat Code Coverage"
- name: Upload to Codecov
uses: codecov/codecov-action@v5
publish:
runs-on: ubuntu-20.04
needs: build
if: ${{ github.event_name == 'push' }}
steps:
- uses: actions/checkout@v4
- name: publish on version change
id: publish_nuget
uses: rohith/publish-nuget@v2
with:
# Filepath of the project to be packaged, relative to root of repository
PROJECT_FILE_PATH: BervProject.Validation.Common/BervProject.Validation.Common.csproj
NUGET_KEY: ${{ secrets.NUGET_API_KEY }}
docs:
runs-on: ubuntu-22.04
if: ${{ github.event_name == 'push' }}
needs: build
steps:
- uses: actions/checkout@v4
- uses: mattnotmitt/doxygen-action@v1
- name: Deploy
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: _site/html/