1.6 KiB
1.6 KiB
0003 — Release workflow
Date: 2026-06-01 Status: accepted
Context
The project needed a consistent, enforced standard for commit messages, changelog generation, versioning, and GitHub releases — especially important since both humans and AI agents (Claude Code, Codex) commit to the repo.
Decision
- commitlint (
@commitlint/config-conventional) enforces conventional commit format at thecommit-msggit hook - husky v9 wires the hooks;
prepareinstalls them onpnpm install - lint-staged runs prettier + eslint on staged files at the
pre-commithook - release-it +
@release-it/conventional-changelogmanages the full release cycle:- bumps
package.jsonversion (semver) - generates/prepends to
CHANGELOG.md - creates a signed git tag (
v{version}) - creates a GitHub Release with the generated notes
- pushes the tag and commit
- bumps
Release commands:
pnpm release— interactive (prompts for increment type)pnpm release:patch/:minor/:major— non-interactivepnpm release:dry— preview without writing anything- Requires
GITHUB_TOKENin env for GitHub Release creation
Conventional commit types: feat, fix, refactor, docs, test, chore, perf, ci, revert
Consequences
- Every commit is validated; bad format is rejected immediately
- CHANGELOG.md is auto-generated from commit history — no manual upkeep
- Releases are reproducible: one command, idempotent output
chore,ci,testcommits are hidden in the changelog;feat,fix,perf,refactor,docsare surfaced