dotnet / Nerdbank.GitVersioning

Stamp your assemblies, packages and more with a unique version generated from a single, simple version.json file and include git commit IDs for non-official builds.
https://www.nuget.org/packages/Nerdbank.GitVersioning
MIT License
1.36k stars 166 forks source link

Simulate the future version #1019

Open nosalan opened 9 months ago

nosalan commented 9 months ago

Question: I want to display an output that the version is about to be upgraded before running the nbgv prepare-release command. In order to display it, I need to get somehow the next future version, which for example depends on the version increment being set in theversion.json file. Is there a way to get the version that nbgv prepare-release will set in a simulative manner?

AArnott commented 9 months ago

No. What if we added a --what-if switch, which prints the new version but doesn't actually make any changes? Do you need the output to be machine-readable, or merely human readable?

nosalan commented 9 months ago

--what-if sounds excellent, preferably with the machine-readable output.

AArnott commented 9 months ago

Great. We'll keep this issue active in case you or others can prepare the PR.

Sponsorship may be an effective way to lead a contributor of this repo to prioritize the feature. As a free and open source library, all or the majority of its development is done without any monetary benefit to its authors, and all of it is made available free of charge. But sponsorship is very much appreciated and, with agreement from a particular contributor and/or the owning team, can be a great way to support the project and help get your favorite features or bugs addressed in an upcoming version. If sponsorship to drive completion of a feature or bug fix is an interesting option to you, please let us know. You can reach out to me privately on keybase.io or gitter.im as well.