Pin the install command instead of asking the reader to substitute - #128
Merged
Conversation
The install snippet said @<release-tag> and the prose above it named the current version, so a reader had to perform a substitution before they could run anything. Give them the command. The version mentions were prose, not pins, so nothing caught them going stale: v0.2.0 shipped with the README banner, both install commands, and three other lines still saying v0.1.9. verify-release.sh now checks the banner and both install commands alongside the three it already enforced, so the next release cannot repeat it.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Reverting the placeholder removal. The install command stays a placeholder on purpose; what it lacked was the link that lets someone turn it into a version. verify-release.sh narrows to the README banner. That is the line that actually claims what is current, and it is the one that went stale when v0.2.0 shipped announcing v0.1.9. A placeholder cannot be pinned and should not be.
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.
The substitution
The install snippet read:
with prose above naming the current version. A reader had to do the substitution before they could run anything. Now it is the command:
(For the record, nothing was wrong with the code block. Fenced blocks render
<release-tag>literally;<...>only disappears in prose, where a renderer treats it as an inline HTML tag.)The stale version, which is the real bug
Those version mentions were prose, not pins, so nothing caught them going stale. v0.2.0 shipped an hour ago with the README banner, both install commands, and three other lines still telling a reader to install
v0.1.9.scripts/verify-release.shenforced three pins and none of these. It now also checks:README.md—Current release: \vX.Y.Z``README.md— the install commanddocs/setup.md— the install commandso the next release cannot ship pointing at the previous one.
Verified
That is step 2 of
docs/release.md, confirmed against the real tag.No new tag needed: the docs now name the version that is already released.