[codex] Support curated release notes files - #71
Merged
Merged
Conversation
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.
Issue
release.shalways generated GitHub release notes from a flat list of commits. Release managers could not supply curated Markdown while keeping the generated commit history available for auditing.User impact
Release notes can now lead with a task-oriented, curated summary without losing the exact commit list. Existing invocations continue to generate the same release-note template when no notes file is supplied.
Root cause
The script treated its only argument as the version bump type and constructed one fixed release-note template. It had no argument state for a notes file and no conditional rendering path.
Fix
--notes <file>.--notesbefore or after the bump type, withpatchstill the default.<details><summary>Commits</summary>.localandread -pusage while touching the script, and stream notes withprintf.Usage
Positional notes file:
Flag form, defaulting to a patch bump:
The flag may also precede the bump type:
Legacy behavior is unchanged:
Validation
cargo fmt --checkcargo clippy --all-targets --all-features -- -D warningscargo test(including 210 unit tests, integration suites, and 75 doctests)sh -n release.shdash -n release.sh--notes, missing flag value, missing file, directory path, duplicate notes, duplicate bump type, invalid bump type, and unknown optionmainbranch guard and thatCargo.toml,rstructor_derive/Cargo.toml,Cargo.lock, and release tags were unchangedNo tag, GitHub release, version bump, or crates.io publication was created during validation.