-
Notifications
You must be signed in to change notification settings - Fork 69
105 lines (90 loc) · 2.66 KB
/
push-main.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
99
100
101
102
103
104
105
name: xUnit.net Analyzers CI Build
on:
push:
branches:
- main
- 'rel/**'
workflow_dispatch:
jobs:
build:
name: "Build"
runs-on: ubuntu-22.04
env:
DOTNET_NOLOGO: true
steps:
- name: Clone source
uses: actions/checkout@v3
with:
fetch-depth: 0
submodules: true
- name: Replace global.json
run: cp .github/workflows/.global.json global.json
shell: bash
- name: Install .NET SDK
uses: actions/setup-dotnet@v3
with:
dotnet-version: |
6.0.x
- name: Get .NET information
run: dotnet --info
- name: Get Mono information
run: mono --version
- name: "Build target: BuildAll"
run: dotnet run --project tools/builder --no-launch-profile -- BuildAll --timing
- name: "Upload artifact: test"
uses: actions/upload-artifact@v3
with:
name: test
path: artifacts/test
if: always()
- name: "Upload artifact: packages"
uses: actions/upload-artifact@v3
with:
name: packages
path: artifacts/packages
if: always()
publish:
name: "Sign and Publish"
runs-on: windows-latest
needs: build
env:
DOTNET_NOLOGO: true
steps:
- name: Clone source
uses: actions/checkout@v3
with:
fetch-depth: 0
submodules: true
- name: Add MSBuild to PATH
uses: microsoft/setup-msbuild@v1
- name: Install .NET SDK
uses: actions/setup-dotnet@v3
with:
dotnet-version: |
6.0.x
7.0.x
- name: Get .NET information
run: dotnet --info
- name: "Download artifact: packages"
uses: actions/download-artifact@v3
with:
name: packages
path: artifacts/packages
- name: "Build target: PublishPackages"
env:
PUSH_APIKEY: ${{ secrets.PUSH_APIKEY }}
PUSH_URI: ${{ secrets.PUSH_URI }}
SIGN_APP_ID: ${{ secrets.SIGN_APP_ID }}
SIGN_APP_SECRET: ${{ secrets.SIGN_APP_SECRET }}
SIGN_CERT_NAME: ${{ secrets.SIGN_CERT_NAME }}
SIGN_SUBSCRIPTION: ${{ secrets.SIGN_SUBSCRIPTION }}
SIGN_TENANT: ${{ secrets.SIGN_TENANT }}
SIGN_TIMESTAMP_URI: ${{ secrets.SIGN_TIMESTAMP_URI }}
SIGN_VAULT_URI: ${{ secrets.SIGN_VAULT_URI }}
run: dotnet run --project tools/builder --no-launch-profile -- PublishPackages --timing
- name: "Upload artifact: packages"
uses: actions/upload-artifact@v3
with:
name: packages
path: artifacts/packages
if: always()