GitVersion Conversion #486
-
Hey all, First, I want to say thanks for this, I'd previously configured GitVersion to essentially do the same thing... more or less, but this works much better, especially when doing prereleases (with GitVersion, tag So, that said, I have a couple of questions. First, is there any way to make the default prerelease versions increment the "primary" digit until a prerelease tag is encountered? So, for example, a series of commits and tags might look like this:
Instead of this:
And second, is there any way to easily query the minver-cli to check if the current version is a prerelease? Perhaps something equivalent to Thanks again! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
As a follow up, for the prerelease query, I think this is always guaranteed to be valid: if [[ "$(minver --tag-prefix=v --verbosity=e)" == *"-"* ]]; then
options+=("--prerelease")
fi But for the first issue, I encountered this on the README:
Did the behavior change at some point? This is what I want (number-wise). |
Beta Was this translation helpful? Give feedback.
-
@AshleighAdams in answer to your first question, the answer is similar to this one — #488 (comment). The behaviour, as far as I can remember has never changed. This was the design from the start. Regarding your second question, checking the version for the presence of |
Beta Was this translation helpful? Give feedback.
@AshleighAdams in answer to your first question, the answer is similar to this one — #488 (comment). The behaviour, as far as I can remember has never changed. This was the design from the start.
Regarding your second question, checking the version for the presence of
-
should work as long as their is no build metadata, which could also contain-
. To be absolutely safe, I would first split the string on+
and then check for the presence of-
in the first substring.