Skip to content

Commit

Permalink
Merge aa88d4f into 1dbfeba
Browse files Browse the repository at this point in the history
  • Loading branch information
chidozieononiwu authored Nov 11, 2020
2 parents 1dbfeba + aa88d4f commit 8fb1237
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
1 change: 1 addition & 0 deletions eng/pipelines/templates/stages/archetype-js-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ stages:
pwsh: true
workingDirectory: $(Build.SourcesDirectory)
filePath: eng/scripts/SetTestPipelineVersion.ps1
arguments: '-BuildNumber $(Build.BuildNumber)'
- template: /eng/common/pipelines/templates/steps/verify-changelog.yml
parameters:
PackageName: ${{artifact.name}}
Expand Down
1 change: 1 addition & 0 deletions eng/pipelines/templates/steps/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ steps:
pwsh: true
workingDirectory: $(Build.SourcesDirectory)
filePath: eng/scripts/SetTestPipelineVersion.ps1
arguments: '-BuildNumber $(Build.BuildNumber)'

- pwsh: |
$folder = "${{parameters.ServiceDirectory}}"
Expand Down
11 changes: 8 additions & 3 deletions eng/scripts/SetTestPipelineVersion.ps1
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
# Overides the project file and CHANGELOG.md for the template project using the next publishable version
# Overides the project file and CHANGELOG.md for the template project.
# This is to help with testing the release pipeline.

param (
[Parameter(mandatory = $true)]
$BuildNumber
)

. "${PSScriptRoot}\..\common\scripts\common.ps1"
$latestTags = git tag -l "@azure/template_*"
$semVars = @()
Expand All @@ -18,8 +23,8 @@ $semVarsSorted = [AzureEngSemanticVersion]::SortVersionStrings($semVars)
LogDebug "Last Published Version $($semVarsSorted[0])"

$newVersion = [AzureEngSemanticVersion]::ParseVersionString($semVarsSorted[0])
$newVersion.IncrementAndSetToPrerelease()
LogDebug "Version to publish [ $($newVersion.ToString()) ]"
$newVersion.PrereleaseLabel = "beta"
$newVersion.PrereleaseNumber = $BuildNumber

$packageFileContent = Get-Content -Path $templatePackageFile | ConvertFrom-Json
LogDebug "Version in Source $($packageFileContent.version)"
Expand Down

0 comments on commit 8fb1237

Please sign in to comment.