-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.yml
59 lines (51 loc) · 1.36 KB
/
main.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
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
name: CI
on:
push:
paths-ignore:
- 'images/**'
- 'docs/**'
- 'examples/**'
- 'packages/**'
- 'README.md'
branches: [ master ]
pull_request:
paths-ignore:
- 'images/**'
- 'docs/**'
- 'examples/**'
- 'packages/**'
- 'README.md'
branches: [ master ]
jobs:
build:
runs-on: ubuntu-latest
defaults:
run:
shell: bash
env:
DOTNET_CLI_TELEMETRY_OPTOUT: 1
DOTNET_DISABLE_GUI_ERRORS: 1
DOTNET_GENERATE_ASPNET_CERTIFICATE: 0
DOTNET_NOLOGO: 1
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 1
- name: Setup .NET 6 SDK
uses: actions/setup-dotnet@v2
with:
dotnet-version: 6.0.x
include-prerelease: false
- name: Remove net framework example project
run: dotnet sln remove "examples\NetFrameworkExample\NetFrameworkExample.csproj"
- name: Restore
run: dotnet restore -p:Configuration=Release
- name: Build
run: |
dotnet build -c Release --no-restore -p:SourceRevisionId=$(git rev-parse --short $GITHUB_SHA)
- name: Test
run: |
dotnet test -c Release --no-restore --no-build --verbosity normal