From 42196922e6b4cf51e30c9ef0acefa4acc52b0f05 Mon Sep 17 00:00:00 2001 From: Max Katz Date: Fri, 8 Mar 2024 17:41:26 -0800 Subject: [PATCH] Update azure-pipelines.yml --- azure-pipelines.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index ad691bcfb2..fb9d98ef80 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -11,6 +11,10 @@ jobs: inputs: targetType: 'inline' script: | + $Namespace = @{ msbuild = "http://schemas.microsoft.com/developer/msbuild/2003" } + $versionBase = Select-Xml -Path build\SharedVersion.props -XPath /msbuild:Project/msbuild:PropertyGroup/msbuild:Version -Namespace $Namespace |ForEach-Object {$_.Node.Innerxml} + Write-Host "Base Version Number is:-" $versionBase + $prId = $env:System_PullRequest_PullRequestNumber Write-Host "PR Number is:-" $env:System_PullRequest_PullRequestNumber @@ -18,6 +22,10 @@ jobs: { Set-Content -Path $env:Build_ArtifactStagingDirectory\prId.txt -Value $prId } + if (!([string]::IsNullOrWhiteSpace($versionBase))) + { + Set-Content -Path $env:Build_ArtifactStagingDirectory\versionBase.txt -Value $versionBase + } - task: PublishBuildArtifacts@1 inputs: