-
Notifications
You must be signed in to change notification settings - Fork 654
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[ISSUE]: There's no NuGetVersionV2 anymore, and no zero-padded PreReleaseNumber #4153
Comments
So we need to stay on 5.x in order to version packages for anything that's not SemVer 2 -- like the official PowerShell gallery. |
Unfortunately, yes. But as a fix to this issue and probably a few other issues as well, would be for GitVersion to support arbitrary C# format strings, so you could create your own padded version number as such: assembly-informational-format: '{Major}.{Minor}.{Patch}-{CommitsSinceVersionSource:0000}' Something like that would be very powerful and definitely something I'd welcome pull requests for. |
Do you know if already a feature ticket has been raised for this? |
I'm actually baffled as to why NuGetVersionV2 was removed... in favor of something more complicated like adding parsing of format strings into a config variable... ??? if NuGetVersionV2 was complicated to calculate then I can understand... theres a lot of people, inclding myself using GitVersion to properly calculate a usable NuGet version... |
Prerequisites
GitVersion package
GitVersion.Tool
GitVersion version
6.0.1
Operating system
N/A
What are you seeing?
I was porting settings from a PowerShell module, and I get this error:
Unable to format AssemblyInformationalVersion. Check your format string: 'NuGetVersionV2' is not a member of type 'GitVersion.SemanticVersionFormatValues' (Parameter 'propertyOrFieldName')
What is expected?
I expected to be able to build a version like "1.2.3-beta0002" so I can upload packages to the PowerShell gallery. chocolatey, and other old nuget-based servers.
Note that the FAQ still refers to a NuGetVersionV2
Steps to Reproduce
Try using this in your GitVersion.yml
The FAQ still refers to a NuGetVersionV2
RepositoryFixture Test
No response
Output log or link to your CI build (if appropriate).
No response
The text was updated successfully, but these errors were encountered: