11steps :
22
3- - task : DownloadBuildArtifacts@0
4- displayName : ' Download Build Artifacts'
5- inputs :
6- downloadType : specific
7-
8- - task : ExtractFiles@1
9- displayName : ' Extract Build Zip'
10- inputs :
11- archiveFilePatterns : ' $(Build.ArtifactStagingDirectory)/PowerShellEditorServices-CI/PowerShellEditorServices*.zip'
12- destinationFolder : ' $(Build.ArtifactStagingDirectory)/PowerShellEditorServices'
3+ - download : current
4+ displayName : Download unsigned pipeline artifacts
135
146- checkout : ComplianceRepo
15- displayName : ' Checkout the ComplianceRepo'
167
8+ # NOTE: The signing templates explicitly copy everything along as they run, so
9+ # the last output path has every signed (and intentionally unsigned) file.
1710- template : EsrpSign.yml@ComplianceRepo
1811 parameters :
19- buildOutputPath : ' $(Build.ArtifactStagingDirectory)/PowerShellEditorServices'
20- signOutputPath : ' $(Build.ArtifactStagingDirectory)/FirstPartySigned'
21- alwaysCopy : true # So publishing works
22- certificateId : ' CP-230012' # Authenticode certificate
23- useMinimatch : true # This enables the use of globbing
12+ buildOutputPath : $(Pipeline.Workspace)/PowerShellEditorServices-Build-*
13+ signOutputPath : $(Pipeline.Workspace)/FirstPartySigned
14+ alwaysCopy : true
15+ certificateId : CP-230012 # Authenticode certificate
2416 shouldSign : true # We always want to sign
17+ useMinimatch : true # This enables the use of globbing
2518 pattern : |
2619 # PowerShellEditorServices Script
2720 PowerShellEditorServices/*.{ps1,psd1,psm1,ps1xml}
@@ -35,12 +28,12 @@ steps:
3528
3629 - template : EsrpSign.yml@ComplianceRepo
3730 parameters :
38- buildOutputPath : ' $(Build.ArtifactStagingDirectory)/FirstPartySigned'
39- signOutputPath : ' $(Build.ArtifactStagingDirectory)/ThirdPartySigned'
40- alwaysCopy : true # So publishing works
41- certificateId : ' CP-231522' # Third-party certificate
42- useMinimatch : true # This enables the use of globbing
31+ buildOutputPath : $(Pipeline.Workspace)/FirstPartySigned
32+ signOutputPath : $(Pipeline.Workspace)/ThirdPartySigned
33+ alwaysCopy : true
34+ certificateId : CP-231522 # Third-party certificate
4335 shouldSign : true # We always want to sign
36+ useMinimatch : true # This enables the use of globbing
4437 pattern : |
4538 **/MediatR.dll
4639 **/Nerdbank.Streams.dll
@@ -49,27 +42,37 @@ steps:
4942 **/Serilog*.dll
5043 **/UnixConsoleEcho.dll
5144
52- - publish : $(Build.ArtifactStagingDirectory)/ThirdPartySigned
45+ - task : ArchiveFiles@2
46+ displayName : Zip finished assets
47+ inputs :
48+ rootFolderOrFile : $(Pipeline.Workspace)/ThirdPartySigned
49+ includeRootFolder : false
50+ archiveType : zip
51+ archiveFile : PowerShellEditorServices.zip
52+ replaceExistingArchive : true
53+ verbose : true
54+
55+ - publish : PowerShellEditorServices.zip
5356 artifact : PowerShellEditorServices
54- displayName : ' Publish signed (and unsigned) artifacts'
57+ displayName : Publish signed pipeline artifacts
5558
5659- checkout : self
5760
5861- template : assembly-module-compliance.yml@ComplianceRepo
5962 parameters :
6063 # binskim
61- AnalyzeTarget : ' $(Build.ArtifactStagingDirectory )/*.dll'
64+ AnalyzeTarget : $(Pipeline.Workspace )/*.dll
6265 AnalyzeSymPath : ' SRV*'
6366 # component-governance
64- sourceScanPath : ' $(Build.SourcesDirectory)/PowerShellEditorServices'
67+ sourceScanPath : $(Build.SourcesDirectory)/PowerShellEditorServices
6568 # credscan
6669 suppressionsFile : ' '
6770 # TermCheck AKA PoliCheck
68- targetArgument : ' $(Build.SourcesDirectory)/PowerShellEditorServices'
69- optionsUEPATH : ' $(Build.SourcesDirectory)/PowerShellEditorServices/tools/terms/UserExclusions.xml'
71+ targetArgument : $(Build.SourcesDirectory)/PowerShellEditorServices
72+ optionsUEPATH : $(Build.SourcesDirectory)/PowerShellEditorServices/tools/terms/UserExclusions.xml
7073 optionsRulesDBPath : ' '
71- optionsFTPath : ' $(Build.SourcesDirectory)/PowerShellEditorServices/tools/terms/FileTypeSet.xml'
74+ optionsFTPath : $(Build.SourcesDirectory)/PowerShellEditorServices/tools/terms/FileTypeSet.xml
7275 # tsa-upload
73- codeBaseName : ' PowerShell_PowerShellEditorServices_20210201'
76+ codeBaseName : PowerShell_PowerShellEditorServices_20210201
7477 # selections
7578 APIScan : false
0 commit comments