-
We use GitVersion in Mainline mode to version a number of repositories in Azure DevOps. For pull requests, we currently get version numbers like Azure DevOps keeps an increasing iteration ID for each pull request, which is available in our build pipelines as I can pass in the iteration as an environment variable and then override some of the assembly version variable formats, for example like Is the only solution to do a bit of post-processing of the GitVersion output before setting |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Indeed, my general recommendation is to post-process GitVersion's output. There's usually a plethora of variables I'm interested in using in my CI/CD pipelines, with GitVersion's calculated version number being one of many. I therefore tend to write a little |
Beta Was this translation helpful? Give feedback.
Indeed, my general recommendation is to post-process GitVersion's output. There's usually a plethora of variables I'm interested in using in my CI/CD pipelines, with GitVersion's calculated version number being one of many. I therefore tend to write a little
variables.sh
script which takes the version number from GitVersion as an argument and transforms that to fit the needs of the repository.