chore(release): v0.4.1, and stop every release needing hand edits - #51
Merged
Merged
Conversation
Lands the bump on main *before* the release runs, which is what the release workflow needs in order to finish green. "Bring the branch up to the released version" checks one thing: is the commit it built from an ancestor of main. It cannot make that true by itself here — GITHUB_TOKEN is not allowed through branch protection, and the pull request fallback needs "Allow GitHub Actions to create and approve pull requests", which is off. That is why v0.4.0's run is red even though the release itself shipped correctly. With every version site already stating 0.4.1, the workflow's own bump step finds nothing to write, tags main's HEAD unchanged, and the ancestor check passes. Also adds docs/release-notes/v0.4.1.md, which the workflow prefers over GitHub's generated commit list. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
…p PR Two things that made every release cost manual edits. The README's checksum example named `winmedic-v<version>.exe` twice, so set-version.ps1 had to rewrite it on every bump — a docs file in the release path for no reason other than two hardcoded filenames. It now globs `winmedic-v*.exe` out of the download directory, which is what the reader has in front of them anyway, and states no version at all. README.md is therefore gone from set-version.ps1's target list, with a note saying why it must not be added back: a target whose pattern never matches makes the script throw. The second is the bump reaching `main`. The workflow cannot push it there — `main` is protected and GITHUB_TOKEN is not allowed through, and the pull request fallback needs a setting that is off — so the last step of every release run goes red, as v0.4.0 did while shipping perfectly. The two documented fixes both hand CI a way past branch protection. prepare-release.ps1 takes the other road: it branches off origin/main, runs set-version.ps1, commits and opens the pull request, so the bump arrives the same reviewed, CI-gated way as every other change. Releasing from a `main` that already states the version then makes the workflow's own bump step a no-op, and the check it failed on passes. It refuses a version that has already shipped, a dirty tree and an existing branch, and points out a missing docs/release-notes/<tag>.md while writing one is still cheap. -NoPush prepares the commit locally without pushing or opening anything. CONTRIBUTING and the workflow's own guidance now describe that path first; CONTRIBUTING also claimed the workflow "brings main up to date", which is the one thing it cannot do. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two commits: the v0.4.1 version bump, and the reason a bump needs its own pull request at all.
chore(release): v0.4.1Raises the version across
Cargo.toml,Cargo.lockand the issue template, and addsdocs/release-notes/v0.4.1.mdcovering #50 and #49.chore(release): stop the README repeating the version, script the bump PRThe README no longer states a version. Its checksum example named
winmedic-v<version>.exetwice, soset-version.ps1rewrote a docs file on every release. It now globswinmedic-v*.exeout of the download directory — which is what the reader has in front of them anyway:Verified against a matching and a tampered file.
README.mdis therefore out ofset-version.ps1's target list, with a note saying why it must not be added back: a target whose pattern never matches makes the script throw.scripts/prepare-release.ps1opens the pull request this one is. The release workflow cannot land its own bump onmain— the branch is protected,GITHUB_TOKENis not allowed through, and the pull-request fallback needs a setting that is off. That is why run #7 went red while v0.4.0 itself shipped perfectly.Both documented fixes hand CI a way past branch protection. This takes the other road — the bump goes down the same reviewed, CI-gated path as every other change:
Releasing from a
mainthat already states the version makes the workflow's own bump step a no-op — it finds every site correct, tagsHEADunchanged, and the check it failed on passes.The script refuses a version that has already shipped, a dirty tree and an existing branch, and warns when
docs/release-notes/<tag>.mdis missing while writing one is still cheap.-NoPushprepares the commit locally without pushing or opening anything. All four paths were exercised locally.CONTRIBUTING.mdand the workflow's own guidance now describe that path first. CONTRIBUTING also claimed the workflow "bringsmainup to date", which is the one thing it cannot do.Does it change what WinMedic does to a system?
Checks
set-version.ps1 0.4.1 -Checkpasses with README removed from its targetsprepare-release.ps1end-to-end with-NoPush, plus its invalid-version, already-shipped-tag and dirty-tree guardsrelease.ymlstill parses; both jobs intact🤖 Generated with Claude Code