Skip to content

feat: automated versioning and workflow_dispatch release process#79

Draft
McNultyyy wants to merge 2 commits into
mainfrom
mcnultyyy/release-workflow-redesign
Draft

feat: automated versioning and workflow_dispatch release process#79
McNultyyy wants to merge 2 commits into
mainfrom
mcnultyyy/release-workflow-redesign

Conversation

@McNultyyy

Copy link
Copy Markdown
Collaborator

Summary

Replaces the manual tag-push release process with a fully automated, workflow_dispatch-driven approach.

What changed

nuget-version.yaml (new)

A single file at the repo root containing only major and minor. This is the only file you ever need to edit for a major or minor version bump. Patches auto-increment.

src/Directory.Build.props

Removed the hardcoded <Version>4.0.20</Version>. Local builds now produce 0.0.0-local. CI/release always pass -p:Version=X.Y.Z at build time.

release.yml (rewritten)

  • Triggered by Actions → Release → Run workflow (manual workflow_dispatch)
  • Single input: Prerelease (beta) checkbox (default: unchecked)
  • Patch auto-increments: queries the highest existing vX.Y.* GitHub release tag and adds 1
  • Concurrency lock: group: release, cancel-in-progress: false — parallel triggers queue safely, preventing version collisions
  • Stable release from main; beta release from any branch or when the prerelease checkbox is ticked
  • Beta format: X.Y.Z-beta.N.sanitised-branch-name
  • Runs full test suite (_build-and-test.yml + _windows-parity.yml) before publishing
  • Creates a GitHub Release with auto-generated notes and uploads .nupkg + .snupkg assets

ci.yml (updated)

Added a version-preview job that runs only on PRs and only when src/, *.props, or nuget-version.yaml files changed. It shows the next beta and stable version in the workflow step summary — no auto-publishing.

AGENTS.md (updated)

Updated the Versioning & Release and Publishing & Releases sections to reflect the new process.

How to release

Stable: merge to main, go to Actions → Release, click Run workflow (leave Prerelease unchecked).

Beta: push your branch, go to Actions → Release, select your branch, tick Prerelease.

Major/minor bump: edit nuget-version.yaml, merge to main, trigger release as normal.

- Add nuget-version.yaml (major/minor only) as version source
- Remove hardcoded version from src/Directory.Build.props; local builds produce 0.0.0-local
- Rewrite release.yml: workflow_dispatch trigger, auto-computed patch from GitHub release history, concurrency serialisation, beta support from non-main branches
- Update ci.yml: add version-preview job (PR-only, path-filtered to src/props/nuget-version.yaml changes) showing next beta and stable version in step summary
- Update AGENTS.md to reflect new no-tag, no-version-bump workflow

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@McNultyyy
McNultyyy requested a review from lemonlion as a code owner June 1, 2026 18:11
@McNultyyy
McNultyyy marked this pull request as draft June 1, 2026 18:12
Move duplicated version bash logic from ci.yml and release.yml into
.github/actions/compute-nuget-version/action.yml.

Outputs: stable-version, beta-version, last-patch.
Both workflows now delegate to the action and use the outputs directly.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant