-
Notifications
You must be signed in to change notification settings - Fork 0
61 lines (56 loc) · 1.78 KB
/
Copy pathpull-request.yaml
File metadata and controls
61 lines (56 loc) · 1.78 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
name: pull-request
on:
pull_request:
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number }}
cancel-in-progress: true
permissions:
contents: read
env:
CONFIGURATION: Staging
jobs:
validate:
strategy:
fail-fast: false
matrix:
include:
- os: windows-latest
name: Windows
package: false
- os: ubuntu-latest
name: Linux
package: true
- os: macos-latest
name: macOS
package: false
name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v4
with:
dotnet-version: |
7.0.x
8.0.x
9.0.x
10.0.x
- run: dotnet restore Icod.Timing.sln
- run: dotnet build Icod.Timing.sln -c ${{ env.CONFIGURATION }} --no-restore -p:ContinuousIntegrationBuild=true
- run: dotnet test Icod.Timing.sln -c ${{ env.CONFIGURATION }} --no-build --no-restore --logger trx
- name: Pack Staging package
if: matrix.package
run: dotnet pack Icod.Timing.csproj -c ${{ env.CONFIGURATION }} --no-build --no-restore -o artifacts -p:ContinuousIntegrationBuild=true
- name: Verify exact Staging package artifacts
if: matrix.package
shell: pwsh
run: ./packaging/VerifyPackageArtifact.ps1 -ArtifactDirectory artifacts -Configuration '${{ env.CONFIGURATION }}'
- name: Upload validated Staging package artifacts
if: matrix.package
uses: actions/upload-artifact@v4
with:
name: icod-timing-pr-packages
path: |
artifacts/*.nupkg
artifacts/*.snupkg
if-no-files-found: error
retention-days: 7