📝 docs(version-release): enforce git-derived PR refs and metrics#14575
Conversation
Add the skill's first-class hard rules for computing release-note inputs from git instead of memory: latest-tag base via `git describe`, PR refs from commit subjects, metric counts from `wc -l`, handle resolution via `gh pr view`, and a pre-publish `comm -23` diff that must be empty. Also adds @cy948 to the team roster and notes Tsuki / René Wang's commit-author aliases so contributor classification stops drifting.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d648f9d8a6
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| gh pr view lobehub/lobe-chat --json author --jq '.author.login' < some-pr-by-them > --repo | ||
| ``` |
There was a problem hiding this comment.
Fix invalid gh command for author handle lookup
The new mandatory author-resolution command is not executable as written: gh pr view expects [<number>|<url>|<branch>] [flags] and --repo requires a repository value, but this example passes lobehub/lobe-chat as the PR argument and leaves --repo valueless; additionally < some-pr-by-them > is parsed by the shell as redirection. In practice this step fails immediately, so contributors cannot be reliably mapped to GitHub handles during release-note generation.
Useful? React with 👍 / 👎.
…rences SKILL.md was 426 lines covering three distinct flows. Split it so each flow lives next to its own checklist: - reference/minor-release.md — minor workflow (lifted from SKILL.md) - reference/patch-release-scenarios.md — patch flows (existing) - reference/release-notes-style.md — long-form changelog standard, template, and Computing Inputs hard rules (lifted from SKILL.md) SKILL.md now reads as a router (~100 lines) with shared CI trigger rules, post-release automation, precheck, and hard rules. Cross-links between references replace the previous in-file jumps. Also fixes a prettier-mangled redirect (`< some-pr-by-them >`) by using a `$PR` variable instead of an angle-bracket placeholder.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## canary #14575 +/- ##
==========================================
- Coverage 68.86% 68.86% -0.01%
==========================================
Files 2634 2634
Lines 232167 232167
Branches 29518 29519 +1
==========================================
- Hits 159884 159883 -1
- Misses 72133 72134 +1
Partials 150 150
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
…ase-notes-style The Canonical Structure was implicitly long-form (Minor / Weekly), and hotfix authors had to read `changelog-example/hotfix.md` to learn it existed. Make the divergence explicit: - New § Variants for Shorter Releases describes Hotfix structure (Scope / What's Fixed / Upgrade / Owner) and DB Migration structure (Migration overview / Operator impact / Rollback) as overrides of the canonical long-form layout. - Renamed the canonical section to "Canonical Structure (Long-Form: Minor / Weekly)" so the boundary is visible. - Added Hotfix entry to Release Size Heuristics. - Added a Hotfix subsection to Quick Checklist so the verification gates differ from long-form (no metric line / no Contributors / Owner resolved via gh).
…ehub#14575) * 📝 docs(version-release): enforce git-derived PR refs and metrics Add the skill's first-class hard rules for computing release-note inputs from git instead of memory: latest-tag base via `git describe`, PR refs from commit subjects, metric counts from `wc -l`, handle resolution via `gh pr view`, and a pre-publish `comm -23` diff that must be empty. Also adds @cy948 to the team roster and notes Tsuki / René Wang's commit-author aliases so contributor classification stops drifting. * ♻️ refactor(version-release): split skill into router + per-flow references SKILL.md was 426 lines covering three distinct flows. Split it so each flow lives next to its own checklist: - reference/minor-release.md — minor workflow (lifted from SKILL.md) - reference/patch-release-scenarios.md — patch flows (existing) - reference/release-notes-style.md — long-form changelog standard, template, and Computing Inputs hard rules (lifted from SKILL.md) SKILL.md now reads as a router (~100 lines) with shared CI trigger rules, post-release automation, precheck, and hard rules. Cross-links between references replace the previous in-file jumps. Also fixes a prettier-mangled redirect (`< some-pr-by-them >`) by using a `$PR` variable instead of an angle-bracket placeholder. * 📝 docs(version-release): add Hotfix and DB Migration variants to release-notes-style The Canonical Structure was implicitly long-form (Minor / Weekly), and hotfix authors had to read `changelog-example/hotfix.md` to learn it existed. Make the divergence explicit: - New § Variants for Shorter Releases describes Hotfix structure (Scope / What's Fixed / Upgrade / Owner) and DB Migration structure (Migration overview / Operator impact / Rollback) as overrides of the canonical long-form layout. - Renamed the canonical section to "Canonical Structure (Long-Form: Minor / Weekly)" so the boundary is visible. - Added Hotfix entry to Release Size Heuristics. - Added a Hotfix subsection to Quick Checklist so the verification gates differ from long-form (no metric line / no Contributors / Owner resolved via gh).
) * 📝 docs(version-release): enforce git-derived PR refs and metrics Add the skill's first-class hard rules for computing release-note inputs from git instead of memory: latest-tag base via `git describe`, PR refs from commit subjects, metric counts from `wc -l`, handle resolution via `gh pr view`, and a pre-publish `comm -23` diff that must be empty. Also adds @cy948 to the team roster and notes Tsuki / René Wang's commit-author aliases so contributor classification stops drifting. * ♻️ refactor(version-release): split skill into router + per-flow references SKILL.md was 426 lines covering three distinct flows. Split it so each flow lives next to its own checklist: - reference/minor-release.md — minor workflow (lifted from SKILL.md) - reference/patch-release-scenarios.md — patch flows (existing) - reference/release-notes-style.md — long-form changelog standard, template, and Computing Inputs hard rules (lifted from SKILL.md) SKILL.md now reads as a router (~100 lines) with shared CI trigger rules, post-release automation, precheck, and hard rules. Cross-links between references replace the previous in-file jumps. Also fixes a prettier-mangled redirect (`< some-pr-by-them >`) by using a `$PR` variable instead of an angle-bracket placeholder. * 📝 docs(version-release): add Hotfix and DB Migration variants to release-notes-style The Canonical Structure was implicitly long-form (Minor / Weekly), and hotfix authors had to read `changelog-example/hotfix.md` to learn it existed. Make the divergence explicit: - New § Variants for Shorter Releases describes Hotfix structure (Scope / What's Fixed / Upgrade / Owner) and DB Migration structure (Migration overview / Operator impact / Rollback) as overrides of the canonical long-form layout. - Renamed the canonical section to "Canonical Structure (Long-Form: Minor / Weekly)" so the boundary is visible. - Added Hotfix entry to Release Size Heuristics. - Added a Hotfix subsection to Quick Checklist so the verification gates differ from long-form (no metric line / no Contributors / Owner resolved via gh).
…ehub#14575) * 📝 docs(version-release): enforce git-derived PR refs and metrics Add the skill's first-class hard rules for computing release-note inputs from git instead of memory: latest-tag base via `git describe`, PR refs from commit subjects, metric counts from `wc -l`, handle resolution via `gh pr view`, and a pre-publish `comm -23` diff that must be empty. Also adds @cy948 to the team roster and notes Tsuki / René Wang's commit-author aliases so contributor classification stops drifting. * ♻️ refactor(version-release): split skill into router + per-flow references SKILL.md was 426 lines covering three distinct flows. Split it so each flow lives next to its own checklist: - reference/minor-release.md — minor workflow (lifted from SKILL.md) - reference/patch-release-scenarios.md — patch flows (existing) - reference/release-notes-style.md — long-form changelog standard, template, and Computing Inputs hard rules (lifted from SKILL.md) SKILL.md now reads as a router (~100 lines) with shared CI trigger rules, post-release automation, precheck, and hard rules. Cross-links between references replace the previous in-file jumps. Also fixes a prettier-mangled redirect (`< some-pr-by-them >`) by using a `$PR` variable instead of an angle-bracket placeholder. * 📝 docs(version-release): add Hotfix and DB Migration variants to release-notes-style The Canonical Structure was implicitly long-form (Minor / Weekly), and hotfix authors had to read `changelog-example/hotfix.md` to learn it existed. Make the divergence explicit: - New § Variants for Shorter Releases describes Hotfix structure (Scope / What's Fixed / Upgrade / Owner) and DB Migration structure (Migration overview / Operator impact / Rollback) as overrides of the canonical long-form layout. - Renamed the canonical section to "Canonical Structure (Long-Form: Minor / Weekly)" so the boundary is visible. - Added Hotfix entry to Release Size Heuristics. - Added a Hotfix subsection to Quick Checklist so the verification gates differ from long-form (no metric line / no Contributors / Owner resolved via gh).
Summary
Hardens the version-release skill so release-note drafting derives every fact from
git, then splits the resulting 426-line file into a router + per-flow references.Motivated by #14563, where the body cited 7 unmerged/non-existent PRs, 9 PR numbers had drifted off the underlying commits, and the "Since v…" base was set to v2.1.53 while main was already at v2.1.56.
Hard-rules (commit 1)
$PREV_TAG = git describe --tags --abbrev=0 origin/main --match 'v*.*.*' …— the only correct compare base; picking the previous weekly's tag silently drops hotfixes.(#XXXX)in the body must come fromgit log "$PREV_TAG..HEAD" --pretty='%s' --no-merges | grep -oE '\(#[0-9]+\)$'. Inferring PR numbers from feature descriptions is banned.PR_COUNT,COMMIT_COUNT,CONTRIBUTOR_COUNT) come fromwc -lon the computed sets.gh pr view --json author, not assumed from%an.comm -23 body_prs actual_prsmust be empty beforegh pr edit.$PREV_TAG..weeklyinstead ofmain..canaryfor changelog inputs.Split into router + references (commit 2)
SKILL.mdwas 426 lines covering three distinct flows. Each flow now lives next to its own checklist:SKILL.mdreference/minor-release.mdSKILL.md)reference/patch-release-scenarios.mdreference/release-notes-style.mdSKILL.md)Cross-links replace previous in-file jumps. Also fixes a prettier-mangled placeholder (
< some-pr-by-them >was being parsed as shell redirect) by using$PR_NUMBERinstead of an angle-bracket placeholder.Why this matters
Both failure modes in #14563 were one verification command away from being caught at draft time. Encoding those commands as hard rules in the skill turns "the writer remembered to check" into "the skill can't be followed without checking." The split keeps
SKILL.mdshort enough to be the entry point an agent actually reads end-to-end, with deep details paged in only for the active flow.Test plan
comm -23should be empty, metrics should match$PREV_TAGresolves to the latest semver tag (not the previous weekly)