-
Notifications
You must be signed in to change notification settings - Fork 0
chore(release): keep the release PR body to the release #116
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,66 @@ | ||
| [workspace] | ||
| # The release PR body: release-plz's default layout, except that the | ||
| # cargo-semver-checks report is cut down to each failed lint and the items it | ||
| # names. The raw report repeats every lint's description and reference links | ||
| # and names the temporary checkout the old version was unpacked into. The | ||
| # check itself stays on: it also bumps the major version for a breaking | ||
| # change no commit declared. | ||
| pr_body = ''' | ||
| {% set changes %} | ||
| {%- for release in releases %} | ||
| {%- if release.changelog %}{% if releases | length > 1 %} | ||
| ## `{{ release.package }}` | ||
| {% endif %} | ||
| <blockquote> | ||
|
|
||
| {% if release.title %}## {{ release.title }} | ||
| {% endif %} | ||
| {{ release.changelog }} | ||
| </blockquote>{% endif %} | ||
| {% endfor %} | ||
| {% endset %} | ||
|
|
||
| ## 🤖 New release | ||
| {% for release in releases %} | ||
| * `{{ release.package }}`: {% if release.previous_version and release.previous_version != release.next_version %}{{ release.previous_version }} -> {% endif %}{{ release.next_version }}{% if release.semver_check == "incompatible" %} (⚠ API breaking changes){% elif release.semver_check == "compatible" %} (✓ API compatible changes){% endif %} | ||
| {%- endfor %} | ||
| {%- for release in releases %}{% if release.breaking_changes %} | ||
|
|
||
| ### ⚠ `{{ release.package }}` breaking changes | ||
|
|
||
| cargo-semver-checks against {{ release.previous_version }}: | ||
| {% for line in release.breaking_changes | split(pat=" | ||
| ") %} | ||
| {%- if line is starting_with(pat="--- failure ") %} | ||
| - {{ line | replace(from="--- failure ", to="") | replace(from=" ---", to="") }} | ||
| {%- elif line is starting_with(pat=" ") and line is containing(pat=" in file ") %} | ||
| - `{{ line | split(pat=" in file ") | first | trim | replace(from=", previously", to="") }}` | ||
| {%- endif %} | ||
| {%- endfor %}{% endif %}{% endfor %} | ||
| {% if changes %} | ||
| <details><summary><i><b>Changelog</b></i></summary><p> | ||
| {{ changes }} | ||
| </p></details> | ||
| {% endif %} | ||
| --- | ||
| This PR was generated with [release-plz](https://github.com/release-plz/release-plz/).''' | ||
|
|
||
| [changelog] | ||
| # Setting the parsers replaces release-plz's defaults, so they are repeated | ||
| # below the one addition. | ||
| commit_parsers = [ | ||
| # The structured-proxy-cli package this commit introduced was never | ||
| # released: the binary moved back into structured-proxy before the next | ||
| # release, so the entry would describe a change no user sees. | ||
| { sha = "90d746b1b3c879359776adaf4bbbac5b97bf1f38", skip = true }, | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
When generating the 5.0.0 changelog, this rule drops the entire Useful? React with 👍 / 👎. |
||
| { message = "^feat", group = "added" }, | ||
| { message = "^changed", group = "changed" }, | ||
| { message = "^deprecated", group = "deprecated" }, | ||
| { message = "^fix", group = "fixed" }, | ||
| { message = "^security", group = "security" }, | ||
| { message = "^.*", group = "other" }, | ||
| ] | ||
|
|
||
| [[package]] | ||
| name = "structured-proxy" | ||
| # Preserve the existing tag scheme (v1.0.0, v1.0.1, ...) instead of the | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When cargo-semver-checks reports a removed Cargo feature, its item line says
in the package's Cargo.toml, notin file. This filter drops the item line, so the release PR flags the breaking change but omits which features were removed. Reviewers must consult the full report to identify them. This loss of review detail does not block merging.Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
Artifacts
Exact Tera rendering test script
Default template render with compatible and breaking reports
PR template render with compatible and breaking reports
Release rendering test inventory and tracked-file status