File tree Expand file tree Collapse file tree 2 files changed +16
-1
lines changed Expand file tree Collapse file tree 2 files changed +16
-1
lines changed Original file line number Diff line number Diff line change @@ -524,6 +524,11 @@ extends:
524524 throw "PDP path '$pdpPath' does not exist. Cannot update PDP.xml."
525525 }
526526
527+ $sbConfigPath = '$(System.DefaultWorkingDirectory)/DSC/.pipelines/store/SBConfig.json'
528+ if (-not (Test-Path -Path $sbConfigPath)) {
529+ throw "SBConfig path '$sbConfigPath' does not exist. Cannot update SBConfig.json."
530+ }
531+
527532 $pdpContent = Get-Content -Path $pdpPath -Raw
528533 $appName = if ($(isPreRelease) -eq 'true') {
529534 'DesiredStateConfiguration-Preview'
@@ -534,6 +539,16 @@ extends:
534539 Set-Content -Path $pdpPath -Value $pdpContent
535540 Write-Host "PDP.xml updated successfully with AppName: $appName"
536541
542+ $sbConfigContent = Get-Content -Path $sbConfigPath -Raw
543+ $productId = if ($(isPreRelease) -eq 'true') {
544+ 'Microsoft.DesiredStateConfiguration-Preview'
545+ } else {
546+ 'Microsoft.DesiredStateConfiguration'
547+ }
548+ $sbConfigContent = $sbConfigContent.Replace('$ProductID$', $productId)
549+ Set-Content -Path $sbConfigPath -Value $sbConfigContent
550+ Write-Host "SBConfig.json updated successfully with ProductID: $productId"
551+
537552 - task : MS-RDX-MRO.windows-store-publish.package-task.store-package@3
538553 displayName : Publish to Microsoft Store
539554 inputs :
Original file line number Diff line number Diff line change 2222 "DisableAutoPackageNameFormatting" : false
2323 },
2424 "appSubmission" : {
25- "productId" : " " ,
25+ "productId" : " $ProductID$ " ,
2626 "targetPublishMode" : " Immediate" ,
2727 "targetPublishDate" : null ,
2828 "visibility" : " NotSet" ,
You can’t perform that action at this time.
0 commit comments