Skip to content

docs: codify release discipline rules + harden release-please config#7

Merged
a-essawy merged 1 commit into
mainfrom
chore/release-discipline-rules
Apr 24, 2026
Merged

docs: codify release discipline rules + harden release-please config#7
a-essawy merged 1 commit into
mainfrom
chore/release-discipline-rules

Conversation

@a-essawy
Copy link
Copy Markdown
Contributor

Summary

Codifies the discipline we discovered we were missing when v1.1.0 shipped as an "empty" bump (install-script PR + prior CI-only PR typed as `fix:` → triggered release-please → binary byte-identical to v1.0.0).

Two file updates:

.claude/rules/conventional-commits.md — rewrite

Replaces the minimal "here are the types and bumps" doc with:

  • R1–R5: the 5 rules that matter, each with the failure mode it prevents
  • Decision matrix: commit type by what-file-changed (src, install scripts, workflows, docs, etc.)
  • Decision matrix: version bump by commit type, post-1.0
  • Anti-patterns: 10 forbidden moves with the reason each is tempting and why it's wrong
  • Pre-commit checklist: 6 questions to stop and answer before every commit
  • NEVER section: `--no-verify`, hand-edits, emoji, subject-line `BREAKING CHANGE:`

Key rule that would have prevented v1.1.0: R1 — `feat:` / `fix:` mean user-visible change, not "new thing in the repo." PR #3's `fix: bulletproof watchdog...` touched only `.github/workflows/watchdog.yml` and should have been `ci:`. That alone would have prevented a version bump.

release-please-config.json — hardened

Two adds:

  1. `pull-request-title-pattern: "chore: release ${version}"` — removes the stray `(main)` component, clean PR titles.
  2. Explicit `changelog-sections` with `hidden: true` on ci/chore/docs/build/refactor/test/style. Belt-and-suspenders — default behavior mostly matches, but this makes it auditable and prevents a future release-please default change from silently polluting the CHANGELOG.

Intentionally not adding `include-paths`. It scopes commit parsing (not just bump filtering), so a `feat:` touching both `src/` and a workflow wouldn't filter correctly. R1+R2 discipline at commit-authoring time is safer.

AGENTS.md / CLAUDE.md

Replaced the bump table with an R1–R5 summary and a link into the full rules file. They remain byte-identical to each other.

Research basis

Audited against astral-sh/uv (user-visible-only CHANGELOG discipline), cli/cli, denoland/deno, and the Conventional Commits v1.0.0 + release-please config schema specs.

No release expected

This is a `docs:` commit per R1's own definition — no bump, no CHANGELOG entry. It's the first commit under the new rules, and the rules predict themselves correctly.

Follow-up

Separate PR will reset release state to a clean v1.0.0 (delete existing v1.0.0 + v1.1.0 tags/releases, reset manifest, `Release-As: 1.0.0`). Safe because adoption is zero (~12h since v1.1.0, no stable install channels caching it). That PR lands only after this one merges.

Test plan

  • PR CI green (test + lint + pr-title)
  • Merge — verify release-please does NOT open a release PR (rule self-validation)
  • Follow-up reset PR proceeds

.claude/rules/conventional-commits.md: rewrite to spell out the 5 rules
that matter (R1 user-visible change discipline, R2 no empty releases,
R3 install scripts as public API, R4 `!` for breaking, R5 release-please
owns tags) plus decision matrices for commit-type-by-what-changed and
version-bump-by-type, anti-patterns to forbid, and a pre-commit checklist.

release-please-config.json: set pull-request-title-pattern to produce
clean PR titles (no stray component), and add explicit changelog-sections
with hidden flags on ci/chore/docs/build/refactor/test/style. Makes the
'what appears in CHANGELOG' rule explicit and auditable; prevents a
future release-please default change from silently polluting history.

AGENTS.md / CLAUDE.md: replace the single bump table with the R1-R5
summary and a link into the full rules file.

No code behavior change. No version bump expected — this is a `docs:`
commit by R1's own definition.
@a-essawy a-essawy merged commit 2434e27 into main Apr 24, 2026
2 checks passed
@a-essawy a-essawy deleted the chore/release-discipline-rules branch April 24, 2026 12:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant