Skip to content

Commit a8618d1

Browse files
committed
Setup VSIX signing
1 parent 64584fc commit a8618d1

File tree

1 file changed

+17
-1
lines changed

1 file changed

+17
-1
lines changed

.pipelines/vscode-powershell-Official.yml

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ extends:
5656
EnableCDPxPAT: false
5757
WindowsHostVersion:
5858
Version: 2022
59-
Network: Netlock
59+
Network: KS3
6060
stages:
6161
- stage: build
6262
jobs:
@@ -108,6 +108,18 @@ extends:
108108
files_to_sign: '**/*.ps1;**/*.psd1;**/*.psm1'
109109
- pwsh: Invoke-Build Package
110110
displayName: Create package
111+
- pwsh: |
112+
npx vsce generate-manifest --packagePath out/powershell-$(vsixVersion).vsix
113+
cp out/powershell-$(vsixVersion).manifest out/powershell-$(vsixVersion).signature.p7s
114+
displayName: Generate VSIX manifest
115+
- task: onebranch.pipeline.signing@1
116+
displayName: Sign VSIX manifest
117+
inputs:
118+
command: sign
119+
cp_code: 'CP-401405'
120+
search_root: $(Build.SourcesDirectory)/out
121+
files_to_sign: |
122+
*.signature.p7s;
111123
- job: test
112124
displayName: Build and run tests
113125
pool:
@@ -211,6 +223,10 @@ extends:
211223
'--azure-credential'
212224
'--packagePath'
213225
'$(drop)/powershell-$(vsixVersion).vsix'
226+
'--manifestPath'
227+
'$(drop)/powershell-$(vsixVersion).manifest'
228+
'--signaturePath'
229+
'$(drop)/powershell-$(vsixVersion).signature.p7s'
214230
if ([bool]::Parse('$(prerelease)')) { '--pre-release' }
215231
)
216232
npm run publish -- @publishArgs

0 commit comments

Comments
 (0)