-
Notifications
You must be signed in to change notification settings - Fork 1
98 lines (84 loc) · 2.39 KB
/
ci.yaml
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
name: Continuous Integration
on: pull_request
env:
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true
DOTNET_CLI_TELEMETRY_OPTOUT: true
NUGET_PACKAGES: ${{ github.workspace }}/.nuget/packages
jobs:
build-linux:
name: Build Linux
if: "!contains(github.event.head_commit.message, 'skip-ci')"
needs: [build-os]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Cache packages
uses: actions/cache@v2
with:
path: ${{ env.NUGET_PACKAGES }}
key: ${{ runner.os }}-nuget-${{ hashFiles('.config/dotnet-tools.json', '**/packages.lock.json') }}
restore-keys: ${{ runner.os }}-nuget-
- name: Setup .NETCore 3.1.402
uses: actions/setup-dotnet@v1
with:
dotnet-version: 3.1.402
- name: Setup .NET 5.x
uses: actions/setup-dotnet@v1
with:
dotnet-version: 5.0.100
- name: Integration Tests
shell: bash
run: |
dotnet tool restore
- name: Build
shell: bash
run: |
dotnet tool restore
dotnet cake --target="Default"
build-os:
name: Build OS
if: "!contains(github.event.head_commit.message, 'skip-ci')"
strategy:
matrix:
kind: ['windows', 'macOS']
include:
- kind: windows
os: windows-latest
- kind: macOS
os: macos-latest
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Cache packages
uses: actions/cache@v2
with:
path: ${{ env.NUGET_PACKAGES }}
key: ${{ runner.os }}-nuget-${{ hashFiles('.config/dotnet-tools.json', '**/packages.lock.json') }}
restore-keys: ${{ runner.os }}-nuget-
- name: Setup .NETCore 3.1.402
uses: actions/setup-dotnet@v1
with:
dotnet-version: 3.1.402
- name: Setup .NET 5.x
uses: actions/setup-dotnet@v1
with:
dotnet-version: 5.0.100
- name: Setup .NET 6.x
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.100
- name: Integration Tests
shell: bash
run: |
dotnet tool restore
- name: Build
shell: bash
run: |
dotnet tool restore
dotnet cake