How to Configure GitVersion for Stable Main Versions and Pre-Release Feature Tags with Patch Increments? #4438
Unanswered
daniil-basanets
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm trying to set up GitVersion (dotnet-gitversion tool version 6.1) so that:
first
becomes-first
).1.89.0
to1.89.1
).Expected Behavior
1.89.0
,1.89.1
,1.90.0
(stable, no pre-release)1.89.0-first.0
,1.89.0-first.2
(after merge, main should update to
1.89.1
)We are following [GitLab Flow][1] in our SDLC, and our repository structure is as follows:
Current GitVersion Configuration
Observed Output
When running dotnet-gitversion /updateassemblyinfo on the main branch, I get:
And a snippet of the git log shows:
My Question
How can I adjust my GitVersion configuration so that the main branch always gets a stable version (without any pre-release tags) and increments the patch version on every commit or merge, while feature branches receive versions with a proper pre-release tag derived from their branch name?
Currently, GitVersion is applying a pre-release tag or not incrementing as expected on the main branch.
Any insights or recommended changes to the configuration would be greatly appreciated!
Beta Was this translation helpful? Give feedback.
All reactions