When committing changes, follow this workflow:
Analyze the workspace: Run
git statusandgit diff(staged and unstaged) to understand all changes.Group changes semantically: Identify logical units of work. Each commit must be atomic — one functional change per commit. Group related files that together implement a single concern.
Write conventional commit messages: Use the format
<type>(<scope>): <description>without a body. Allowed types:feat: new featurefix: bug fixrefactor: code restructuring without behavior changedocs: documentation onlystyle: formatting, whitespace, semicolons (no logic change)test: adding or updating testschore: tooling, configs, dependenciesperf: performance improvementci: CI/CD changesbuild: build system changesrevert: reverting a previous commit
Commit rules:
- One-line messages only — never use a commit body.
- Never include commit bodies, trailers, co-author lines, AI/tool attribution, generated-by markers, bot signatures, or metadata implying AI involvement.
- Use
git addfor specific files per commit, nevergit add .unless all changes belong to one commit. - After each commit, run
git log -1 --format=%Band verify the final message contains no AI-related attribution or metadata, then rungit statusto verify success.
Execution order: Stage and commit one group at a time. Do not skip ahead.