@@ -2,9 +2,10 @@ name: ci
2
2
3
3
on :
4
4
push :
5
- branches : [ main ]
5
+ branches : [ main, v* ]
6
6
pull_request :
7
- branches : [ main ]
7
+ branches : [ main, v* ]
8
+ workflow_dispatch :
8
9
9
10
jobs :
10
11
windows-x64 :
40
41
shell : cmd
41
42
- uses : actions/upload-artifact@v3
42
43
with :
43
- name : ${{ matrix.os }}_${{ matrix.configuration }}_x86
44
+ name : ${{ matrix.os }}_${{ matrix.configuration }}_${{ matrix.architecture }}
44
45
path : |
45
46
./artifacts/bin/**/*
46
47
./artifacts/log/**/*
96
97
env :
97
98
EXCLUDE_RUN_ID_FROM_PACKAGE : true
98
99
EXCLUDE_SUFFIX_FROM_VERSION : false
99
- - uses : actions/setup-dotnet@v2
100
- if : ${{ github.event_name == 'push' }}
101
- with :
102
- dotnet-version : ' 6.0.x'
103
- - run : dotnet tool install --tool-path ./artifacts/tools SignClient
104
- if : ${{ github.event_name == 'push' }}
105
- - run : ./artifacts/tools/SignClient "Sign" --baseDirectory "${{ github.workspace }}/artifacts/pkg" --input "**/*.nupkg" --config "${{ github.workspace }}/scripts/SignClientSettings.json" --filelist "${{ github.workspace }}/scripts/SignClientFileList.txt" --user "${{ secrets.SC_USER }}" --secret "${{ secrets.SC_PASS }}" --name "ClangSharp" --description "ClangSharp" --descriptionUrl "https://github.com/dotnet/clangsharp"
106
- if : ${{ github.event_name == 'push' }}
107
100
- uses : actions/upload-artifact@v3
108
101
with :
109
102
name : nuget_preview
@@ -113,6 +106,29 @@ jobs:
113
106
./artifacts/pkg/**/*
114
107
./artifacts/tst/**/*
115
108
if-no-files-found : error
109
+ sign-nuget-preview :
110
+ runs-on : windows-latest
111
+ if : ${{ github.event_name == 'push' }}
112
+ needs : [ build-nuget-preview ]
113
+ permissions :
114
+ id-token : write
115
+ steps :
116
+ - uses : actions/checkout@v3
117
+ - uses : actions/download-artifact@v3
118
+ with :
119
+ name : nuget_preview
120
+ path : ./artifacts
121
+ - uses : actions/setup-dotnet@v3
122
+ with :
123
+ dotnet-version : ' 6.0.x'
124
+ - run : dotnet tool install --tool-path ./artifacts/tools sign --version 0.9.0-beta.23063.3
125
+ - run : ./artifacts/tools/sign code azure-key-vault "**/*.nupkg" --timestamp-url "http://timestamp.digicert.com" --base-directory "${{ github.workspace }}/artifacts/pkg" --file-list "${{ github.workspace }}/scripts/SignClientFileList.txt" --publisher-name ".NET Foundation" --description "LLVMSharp" --description-url "https://github.com/dotnet/llvmsharp" --azure-key-vault-certificate "${{ secrets.SC_KEY_VAULT_CERTIFICATE_ID }}" --azure-key-vault-client-id "${{ secrets.SC_AZURE_CLIENT_ID }}" --azure-key-vault-client-secret "${{ secrets.SC_AZURE_CLIENT_SECRET }}" --azure-key-vault-tenant-id "${{ secrets.SC_AZURE_TENANT_ID }}" --azure-key-vault-url "${{ secrets.SC_KEY_VAULT_URL }}"
126
+ - uses : actions/upload-artifact@v3
127
+ with :
128
+ name : sign_nuget_preview
129
+ path : |
130
+ ./artifacts/pkg/**/*
131
+ if-no-files-found : error
116
132
build-nuget-release :
117
133
runs-on : windows-latest
118
134
steps :
@@ -122,14 +138,6 @@ jobs:
122
138
env :
123
139
EXCLUDE_RUN_ID_FROM_PACKAGE : true
124
140
EXCLUDE_SUFFIX_FROM_VERSION : true
125
- - uses : actions/setup-dotnet@v2
126
- if : ${{ github.event_name == 'push' }}
127
- with :
128
- dotnet-version : ' 6.0.x'
129
- - run : dotnet tool install --tool-path ./artifacts/tools SignClient
130
- if : ${{ github.event_name == 'push' }}
131
- - run : ./artifacts/tools/SignClient "Sign" --baseDirectory "${{ github.workspace }}/artifacts/pkg" --input "**/*.nupkg" --config "${{ github.workspace }}/scripts/SignClientSettings.json" --filelist "${{ github.workspace }}/scripts/SignClientFileList.txt" --user "${{ secrets.SC_USER }}" --secret "${{ secrets.SC_PASS }}" --name "ClangSharp" --description "ClangSharp" --descriptionUrl "https://github.com/dotnet/clangsharp"
132
- if : ${{ github.event_name == 'push' }}
133
141
- uses : actions/upload-artifact@v3
134
142
with :
135
143
name : nuget_release
@@ -139,12 +147,35 @@ jobs:
139
147
./artifacts/pkg/**/*
140
148
./artifacts/tst/**/*
141
149
if-no-files-found : error
150
+ sign-nuget-release :
151
+ runs-on : windows-latest
152
+ if : ${{ github.event_name == 'push' }}
153
+ needs : [ build-nuget-release ]
154
+ permissions :
155
+ id-token : write
156
+ steps :
157
+ - uses : actions/checkout@v3
158
+ - uses : actions/download-artifact@v3
159
+ with :
160
+ name : nuget_release
161
+ path : ./artifacts
162
+ - uses : actions/setup-dotnet@v3
163
+ with :
164
+ dotnet-version : ' 6.0.x'
165
+ - run : dotnet tool install --tool-path ./artifacts/tools sign --version 0.9.0-beta.23063.3
166
+ - run : ./artifacts/tools/sign code azure-key-vault "**/*.nupkg" --timestamp-url "http://timestamp.digicert.com" --base-directory "${{ github.workspace }}/artifacts/pkg" --file-list "${{ github.workspace }}/scripts/SignClientFileList.txt" --publisher-name ".NET Foundation" --description "LLVMSharp" --description-url "https://github.com/dotnet/llvmsharp" --azure-key-vault-certificate "${{ secrets.SC_KEY_VAULT_CERTIFICATE_ID }}" --azure-key-vault-client-id "${{ secrets.SC_AZURE_CLIENT_ID }}" --azure-key-vault-client-secret "${{ secrets.SC_AZURE_CLIENT_SECRET }}" --azure-key-vault-tenant-id "${{ secrets.SC_AZURE_TENANT_ID }}" --azure-key-vault-url "${{ secrets.SC_KEY_VAULT_URL }}"
167
+ - uses : actions/upload-artifact@v3
168
+ with :
169
+ name : sign_nuget_release
170
+ path : |
171
+ ./artifacts/pkg/**/*
172
+ if-no-files-found : error
142
173
publish-nightlies-azure :
143
174
runs-on : ubuntu-latest
144
175
if : ${{ github.event_name == 'push' }}
145
- needs : [ windows-x64, windows-x86, linux-x64, macos-x64, build -nuget-preview ]
176
+ needs : [ windows-x64, windows-x86, linux-x64, macos-x64, sign -nuget-preview, sign-nuget-release ]
146
177
steps :
147
- - uses : actions/download-artifact@v2
178
+ - uses : actions/download-artifact@v3
148
179
with :
149
180
name : windows_release_x64
150
181
path : ./artifacts
@@ -158,9 +189,9 @@ jobs:
158
189
publish-nightlies-github :
159
190
runs-on : ubuntu-latest
160
191
if : false
161
- needs : [ windows-x64, windows-x86, linux-x64, macos-x64, build -nuget-preview ]
192
+ needs : [ windows-x64, windows-x86, linux-x64, macos-x64, sign -nuget-preview, sign-nuget-release ]
162
193
steps :
163
- - uses : actions/download-artifact@v2
194
+ - uses : actions/download-artifact@v3
164
195
with :
165
196
name : windows_release_x64
166
197
path : ./artifacts
0 commit comments