Open vpenades opened 6 years ago
I'm not sure what is typically done for open source NuGet packages. What you're saying sounds reasonable to me for now. I'm hoping we can automate this in the build somehow eventually.
As far as I know, nuget packages use Semantic Versioning, which is horribly complicated to make fully automated, because it involves detecting breaking API changes with the previous versions.
At some point, most projects I've seen have some sort of human involvement when choosing major version.
Given that final (major) versions are released from time to time, and what you would typically release quite often is pre-release packages, I've came to this format for my packages:
1.0.0-alpha-170913-202630
Where 1.0.0 is set manually, and 170913-202630 is the UTC DateTime of the compilation, set automatically.
So every time you compile, you get a new "alpha" package in the directory, so it's very easy to just upload a new prerelease.
More info on package versioning here.
If you like this versioning model, I could edit the csproj to add this automatic versioning feature.
My opinion is to go with your first proposal for now. If we find that we are making more frequent changes/releases, then we can consider other options.
I've uploaded a prelease version with your recent changes: https://www.nuget.org/packages/glTF2Loader/1.1.0-alpha
Will see how it goes.
Thanks!, I'll give it a try 😄
IMO, the most convenient way to handle this is to rely on GitVersion, and github actions to automate builds and publishing nugets on the nuget.org repository. I set this up on my own repo which you can use as a reference if you like it: https://github.com/thomashilke/KineticConvolution. The versioning configuration is defined by the file GitVersion.yml
, and the github action is defined in .github/workflows/build-deploy.yml
.
With this particular setup, builds and build validations are automatically triggered for commits on master and on PR branches, and creating a release from github interface trig a the action to automatically push the nuget on nuget.org.
@thomashilke That seems reasonable, but it would be great if someone wanted to contribute a PR to make this happen.
Right now, the project is set to version 1.0.0, even if that particular version has already been released.
I would like to propose this procedure for releasing final and pre-release packages:
It could be interesting to upload pre-release packages too...