Created
September 11, 2019 08:46
-
-
Save mikeblakeuk/e94c0748a2b6a401b683e641882b934f to your computer and use it in GitHub Desktop.
How to SemVer using DevOps
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
variables: | |
majorMinor: $[ format('{0:yyyy}.{0:M}', pipeline.startTime) ] #or 1.2 | |
buildCounter: $[ counter(format('{0}_{1}', variables['Build.BuildName'], variables['Build.SourceBranchName']), 1) ] | |
develop_Branch: $[ format('{0}.{1}', variables['majorMinor'] , variables['buildCounter']) ] | |
preReleaseBranch: $[ format('{0}-{1}', variables['develop_Branch'], variables['Build.SourceBranchName']) ] | |
semVer: $[ coalesce(variables[format('{0}{1}', variables['Build.SourceBranchName'], '_Branch')], variables['preReleaseBranch']) ] | |
name: $(semVer)+$(BuildID) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment