Skip to content

Use GitVersion and let GA and rc tags publish to nuget.org - #728

Merged
dennisdoomen merged 1 commit into
Fallout-build:release/v10.5from
dennisdoomen:feature/gitversion-tag-driven-releases
Oct 22, 2026
Merged

dennisdoomen merged 1 commit into
Fallout-build:release/v10.5from
dennisdoomen:feature/gitversion-tag-driven-releases

Conversation

@dennisdoomen

@dennisdoomen dennisdoomen commented Oct 22, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

v10.5.0-rc.2 built as 10.5.0-preview.31. The version came from version.json, and nobody changed it on the release branch. The tag did not set the version.

nuget.org also needed a manual dispatch and an approval for every release.

Outcome

Versions come from the branch and the tag. A tag push is enough to release. See ADR-0011.

Trigger Version Goes to
Push to develop -alpha.N GitHub Packages
Push to release/* -beta.N GitHub Packages
Tag X.Y.Z-rc.N or X.Y.Z as tagged nuget.org + GitHub Packages + Release
Other prerelease tag as tagged GitHub Packages + Release

Changes

  • GitVersion (GitVersion.yml, GitFlow preset) replaces Nerdbank.GitVersioning. version.json is deleted.
  • Tags have no v prefix. The release workflow passes the tag to the build as ReleaseTag, and the tag is the package version.
  • No approval step for nuget.org. Remove the required reviewers from the nuget-org environment in repo settings.
  • Before merge: add refs/tags/[0-9]* to tag ruleset 17017817. It only covers refs/tags/v* now, so without this any writer can push 10.5.0 and publish to nuget.org.
  • The preview workflow also runs on release/**. The prune workflow also removes old -alpha and -beta versions.
  • Docs and the cutting-a-release skill updated.

Checked

  • dotnet-gitversion gives 10.5.0-beta.1 on release/v10.5 and release/10.5, 10.5.0-alpha.N on develop, 10.4.1-N on main and 10.3.24-N on support/v10.
  • ./build.ps1 Pack works locally. Compile --release-tag 10.5.0-rc.3 works, and --release-tag v10.5.0 fails with a clear message.
  • Not checked: a real tag build in CI. The first -rc tag after merge is the real test.

Notes

  • Assembly versions are Major.Minor.0.0 (assembly-versioning-scheme: MajorMinor), the same for branch and tag builds.
  • The existing v10.5.0-rc.2 tag and its empty immutable release stay. Use 10.5.0-rc.3 next.

🤖 Generated with Claude Code

@dennisdoomen dennisdoomen added enhancement New feature or request target/vCurrent Targets the current version labels Oct 22, 2026
- Replace Nerdbank.GitVersioning and version.json with GitVersion (GitFlow preset).
  develop builds are -alpha.N, release/* builds are -beta.N.
- Tags have no "v" prefix. The release workflow passes the tag to the build
  as ReleaseTag, and the tag becomes the package version.
- GA and -rc tags publish to nuget.org without approval. Other prerelease
  tags skip nuget.org.
- Preview workflow also runs on release/** pushes.
- Prune workflow also removes old -alpha and -beta versions.
- Add ADR-0011 and update the release docs.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@dennisdoomen
dennisdoomen force-pushed the feature/gitversion-tag-driven-releases branch from 38df22b to fc01d7b Compare October 22, 2026 19:53
@dennisdoomen
dennisdoomen marked this pull request as ready for review October 22, 2026 20:08
@dennisdoomen
dennisdoomen merged commit c6d747a into Fallout-build:release/v10.5 Oct 22, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request target/vCurrent Targets the current version

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant