1
1
steps :
2
2
3
+ # TODO: Replace build artifacts with pipeline artifacts
3
4
- task : DownloadBuildArtifacts@0
4
- displayName : ' Download Build Artifacts '
5
+ displayName : Download build artifacts
5
6
inputs :
6
7
downloadType : specific
7
8
8
9
- task : ExtractFiles@1
9
- displayName : ' Extract Build Zip '
10
+ displayName : Unzip build artifacts
10
11
inputs :
11
- archiveFilePatterns : ' $(Build.ArtifactStagingDirectory)/PowerShellEditorServices-CI/PowerShellEditorServices*.zip'
12
- destinationFolder : ' $(Build.ArtifactStagingDirectory)/PowerShellEditorServices '
12
+ archiveFilePatterns : $(Build.ArtifactStagingDirectory)/PowerShellEditorServices-CI/PowerShellEditorServices*.zip
13
+ destinationFolder : $(Build.ArtifactStagingDirectory)/Unsigned
13
14
14
15
- checkout : ComplianceRepo
15
- displayName : ' Checkout the ComplianceRepo'
16
16
17
+ # NOTE: The signing templates explicitly copy everything along as they run, so
18
+ # the last output path has every signed (and intentionally unsigned) file.
17
19
- template : EsrpSign.yml@ComplianceRepo
18
20
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
21
+ buildOutputPath : $(Build.ArtifactStagingDirectory)/Unsigned
22
+ signOutputPath : $(Build.ArtifactStagingDirectory)/FirstPartySigned
23
+ alwaysCopy : true
24
+ certificateId : CP-230012 # Authenticode certificate
24
25
shouldSign : true # We always want to sign
26
+ useMinimatch : true # This enables the use of globbing
25
27
pattern : |
26
28
# PowerShellEditorServices Script
27
29
PowerShellEditorServices/*.{ps1,psd1,psm1,ps1xml}
@@ -35,12 +37,12 @@ steps:
35
37
36
38
- template : EsrpSign.yml@ComplianceRepo
37
39
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
40
+ buildOutputPath : $(Build.ArtifactStagingDirectory)/FirstPartySigned
41
+ signOutputPath : $(Build.ArtifactStagingDirectory)/ThirdPartySigned
42
+ alwaysCopy : true
43
+ certificateId : CP-231522 # Third-party certificate
43
44
shouldSign : true # We always want to sign
45
+ useMinimatch : true # This enables the use of globbing
44
46
pattern : |
45
47
**/MediatR.dll
46
48
**/Nerdbank.Streams.dll
@@ -49,9 +51,19 @@ steps:
49
51
**/Serilog*.dll
50
52
**/UnixConsoleEcho.dll
51
53
52
- - publish : $(Build.ArtifactStagingDirectory)/ThirdPartySigned
54
+ - task : ArchiveFiles@2
55
+ displayName : Zip finished assets
56
+ inputs :
57
+ rootFolderOrFile : $(Build.ArtifactStagingDirectory)/ThirdPartySigned
58
+ includeRootFolder : false
59
+ archiveType : zip
60
+ archiveFile : $(Build.ArtifactStagingDirectory)/PowerShellEditorServices.zip
61
+ replaceExistingArchive : true
62
+ verbose : true
63
+
64
+ - publish : $(Build.ArtifactStagingDirectory)/PowerShellEditorServices.zip
53
65
artifact : PowerShellEditorServices
54
- displayName : ' Publish signed (and unsigned) artifacts'
66
+ displayName : Publish signed pipeline artifacts
55
67
56
68
- checkout : self
57
69
0 commit comments