[release/v7.5] Separate store automation service endpoints and resolve AppID (#26266)

This commit is contained in:
PowerShell Team Bot
2026-02-11 15:29:58 -08:00
committed by GitHub
parent 20b207d4c0
commit 8d087587c7
2 changed files with 55 additions and 12 deletions
+22 -4
View File
@@ -206,14 +206,32 @@ jobs:
}
Write-Host "##vso[task.setvariable variable=ServiceConnection]$($config.ServiceEndpoint)"
Write-Host "##vso[task.setvariable variable=SBConfigPath]$($config.SBConfigPath)"
Write-Host "##vso[task.setvariable variable=SBConfigPath]$($sbConfigPath)"
# These variables are used in the next tasks to determine which ServiceEndpoint to use
Write-Host "##vso[task.setvariable variable=LTS]$($IsLTS.ToString().ToLower())"
Write-Host "##vso[task.setvariable variable=STABLE]$($IsStable.ToString().ToLower())"
Write-Host "##vso[task.setvariable variable=PREVIEW]$($IsPreview.ToString().ToLower())"
name: UpdateConfigs
displayName: Update PDPs and SBConfig.json
- task: MS-RDX-MRO.windows-store-publish-dev.package-task.store-package@3
displayName: 'Create StoreBroker Package'
- task: MS-RDX-MRO.windows-store-publish.package-task.store-package@3
displayName: 'Create StoreBroker Package (Preview)'
condition: eq('$(PREVIEW)', 'true')
inputs:
serviceEndpoint: '$(ServiceConnection)'
serviceEndpoint: 'StoreAppPublish-Preview'
sbConfigPath: '$(SBConfigPath)'
sourceFolder: '$(BundleDir)'
contents: '*.msixBundle'
outSBName: 'PowerShellStorePackage'
pdpPath: '$(System.DefaultWorkingDirectory)/PowerShell/.pipelines/store/PDP/PDP'
pdpMediaPath: '$(System.DefaultWorkingDirectory)/PowerShell/.pipelines/store/PDP/PDP-Media'
- task: MS-RDX-MRO.windows-store-publish.package-task.store-package@3
displayName: 'Create StoreBroker Package (Stable/LTS)'
condition: or(eq('$(STABLE)', 'true'), eq('$(LTS)', 'true'))
inputs:
serviceEndpoint: 'StoreAppPublish-Stable'
sbConfigPath: '$(SBConfigPath)'
sourceFolder: '$(BundleDir)'
contents: '*.msixBundle'
+33 -8
View File
@@ -47,7 +47,8 @@ jobs:
$middleURL = $matches[1]
}
$endURL = $tagString -replace '[v\.]',''
$endURL = $tagString -replace '^v','' -replace '\.',''
$message = "Changelog: https://github.com/PowerShell/PowerShell/blob/master/CHANGELOG/$middleURL.md#$endURL"
Write-Verbose -Verbose "Release Notes for the Store:"
Write-Verbose -Verbose "$message"
@@ -81,7 +82,6 @@ jobs:
}
}
# Determine the current channel
$currentChannel = if ($IsLTS) { 'LTS' }
elseif ($IsStable) { 'Stable' }
elseif ($IsPreview) { 'Preview' }
@@ -89,8 +89,20 @@ jobs:
Write-Error "No valid channel detected"
exit 1
}
$config = $channelConfigs[$currentChannel]
# Assign AppID for Store-Publish Task
$appID = $null
if ($IsLTS) {
$appID = '$(AppID-LTS)'
}
elseif ($IsStable) {
$appID = '$(AppID-Stable)'
}
else {
$appID = '$(AppID-Preview)'
}
Write-Host "##vso[task.setvariable variable=AppID]$appID"
Write-Verbose -Verbose "Selected channel: $currentChannel"
Write-Verbose -Verbose "App ID: $($config.AppId)"
Write-Verbose -Verbose "Service Endpoint: $($config.ServiceEndpoint)"
@@ -102,11 +114,24 @@ jobs:
displayName: 'Set StoreBroker Configurations'
- task: MS-RDX-MRO.windows-store-publish.publish-task.store-publish@3
displayName: 'Publish LTS StoreBroker Package'
condition: ne('${{ parameters.skipMSIXPublish }}', 'true')
displayName: 'Publish StoreBroker Package (Stable/LTS)'
condition: and(ne('${{ parameters.skipMSIXPublish }}', 'true'), or(eq('$(STABLE)', 'true'), eq('$(LTS)', 'true')))
inputs:
serviceEndpoint: '$(SelectedServiceEndpoint)'
appId: '$(SelectedAppId)'
serviceEndpoint: 'StoreAppPublish-Stable'
appId: '$(AppID)'
inputMethod: JsonAndZip
jsonPath: '$(Pipeline.Workspace)\SBOutDir\PowerShellStorePackage.json'
zipPath: '$(Pipeline.Workspace)\SBOutDir\PowerShellStorePackage.zip'
numberOfPackagesToKeep: 2
jsonZipUpdateMetadata: true
targetPublishMode: 'Immediate'
- task: MS-RDX-MRO.windows-store-publish.publish-task.store-publish@3
displayName: 'Publish StoreBroker Package (Preview)'
condition: and(ne('${{ parameters.skipMSIXPublish }}', 'true'), eq('$(PREVIEW)', 'true'))
inputs:
serviceEndpoint: 'StoreAppPublish-Preview'
appId: '$(AppID)'
inputMethod: JsonAndZip
jsonPath: '$(Pipeline.Workspace)\SBOutDir\PowerShellStorePackage.json'
zipPath: '$(Pipeline.Workspace)\SBOutDir\PowerShellStorePackage.zip'