@@ -19,17 +19,6 @@ schedules:
19
19
- main
20
20
always : true
21
21
22
- parameters :
23
- - name : debug
24
- displayName : Enable debug output
25
- type : boolean
26
- default : false
27
-
28
- variables :
29
- system.debug : ${{ parameters.debug }}
30
- BuildConfiguration : Release
31
- WindowsContainerImage : onebranch.azurecr.io/windows/ltsc2022/vse2022:latest
32
-
33
22
resources :
34
23
repositories :
35
24
- repository : templates
@@ -45,9 +34,25 @@ resources:
45
34
stages :
46
35
- release
47
36
37
+ parameters :
38
+ - name : debug
39
+ displayName : Enable debug output
40
+ type : boolean
41
+ default : false
42
+ - name : OfficialBuild
43
+ displayName : Use Official OneBranch template
44
+ type : boolean
45
+ default : false
46
+
47
+ variables :
48
+ system.debug : ${{ parameters.debug }}
49
+ BuildConfiguration : Release
50
+ WindowsContainerImage : onebranch.azurecr.io/windows/ltsc2022/vse2022:latest
51
+ OneBranchTemplate : ${{ iif(parameters.OfficialBuild, 'v2/OneBranch.Official.CrossPlat.yml@templates', 'v2/OneBranch.NonOfficial.CrossPlat.yml@templates') }}
52
+
48
53
extends :
49
54
# https://aka.ms/obpipelines/templates
50
- template : v2/OneBranch.Official.CrossPlat.yml@templates
55
+ template : ${{ variables.OneBranchTemplate }}
51
56
parameters :
52
57
globalSdl : # https://aka.ms/obpipelines/sdl
53
58
asyncSdl :
@@ -90,14 +95,15 @@ extends:
90
95
inputs :
91
96
version : 20.x
92
97
- task : DownloadPipelineArtifact@2
93
- displayName : Download PowerShellEditorServices
98
+ displayName : Download Official PowerShellEditorServices
94
99
inputs :
95
100
source : specific
96
- project : PowerShellCore
97
- definition : 2905
101
+ project : One
102
+ definition : 136077443
98
103
specificBuildWithTriggering : true
99
104
allowPartiallySucceededBuilds : true
100
105
buildVersionToDownload : latestFromBranch
106
+ tags : onebranch_build_type_official
101
107
branchName : refs/heads/main
102
108
artifact : drop_build_main
103
109
- task : ExtractFiles@1
@@ -135,9 +141,9 @@ extends:
135
141
files_to_sign : " *.signature.p7s"
136
142
- stage : release
137
143
dependsOn : build
138
- condition : eq(variables['Build.Reason'], 'Manual' )
144
+ condition : and(succeeded(), ${{ eq(parameters.OfficialBuild, true) }} )
139
145
variables :
140
- ob_release_environment : Production
146
+ ob_release_environment : ${{ iif(parameters.OfficialBuild, ' Production', 'Test') }}
141
147
version : $[ stageDependencies.build.main.outputs['package.version'] ]
142
148
vsixVersion : $[ stageDependencies.build.main.outputs['package.vsixVersion'] ]
143
149
prerelease : $[ stageDependencies.build.main.outputs['package.prerelease'] ]
@@ -154,7 +160,7 @@ extends:
154
160
- task : GitHubRelease@1
155
161
displayName : Create GitHub release
156
162
inputs :
157
- gitHubConnection : GitHub
163
+ gitHubConnection : github.com_andyleejordan
158
164
repositoryName : PowerShell/vscode-powershell
159
165
target : main
160
166
assets : |
@@ -168,19 +174,7 @@ extends:
168
174
addChangeLog : false
169
175
releaseNotesSource : inline
170
176
releaseNotesInline : " <!-- TODO: Generate release notes on GitHub! -->"
171
- - job : validation
172
- displayName : Manual validation
173
- pool :
174
- type : server
175
- timeoutInMinutes : 1440
176
- steps :
177
- - task : ManualValidation@0
178
- displayName : Wait 24 hours for validation
179
- inputs :
180
- notifyUsers : $(Build.RequestedForEmail)
181
- instructions : Please validate the release and then publish it!
182
177
- job : vscode
183
- dependsOn : validation
184
178
displayName : Publish to VS Code Marketplace
185
179
pool :
186
180
type : release
@@ -190,16 +184,16 @@ extends:
190
184
artifactName : drop_build_main
191
185
workflow : vsce
192
186
vsce :
193
- serviceConnection : vscode-marketplace
187
+ serviceConnection : powershell- vscode-marketplace
194
188
vsixPath : " $(Pipeline.Workspace)/powershell-$(vsixVersion).vsix"
195
189
signaturePath : " $(Pipeline.Workspace)/powershell-$(vsixVersion).signature.p7s"
196
190
manifestPath : " $(Pipeline.Workspace)/powershell-$(vsixVersion).manifest"
197
191
preRelease : $(prerelease)
198
192
useCustomVSCE : true
199
193
feed :
200
- organization : mscodehub
201
- project : PowerShellCore
202
- feedName : PowerShellCore_PublicPackages
194
+ organization : msazure
195
+ project : One
196
+ feedName : npmjs
203
197
steps :
204
198
- pwsh : |
205
199
Write-Host Publishing: $(vsixVersion), pre-release: $(prerelease)
0 commit comments