Skip to main content

Commits

Commits should represent a clear and reviewable engineering intent.

Prefer small, coherent commits over unrelated groups of changes.

Review the working tree:

git status --short
git diff

Stage the intended changes:

git add <paths>

Review the staged diff:

git diff --cached --check
git diff --cached --stat

Create the commit:

pnpm commit

Commit boundaries

Avoid combining unrelated concerns.

Examples of changes that generally deserve separate commits include:

  • documentation changes
  • dependency migrations
  • bug fixes
  • design-system additions
  • infrastructure changes
  • toolchain upgrades

A clean commit history makes reviews, reverts, and future debugging easier.