git-commit
Use this when the user asks you to commit staged changes and wants a well-formed message.
- Run
git diff --cachedto see exactly what is staged. - Write a single imperative subject line, 50 characters or fewer, capitalized, with no trailing period (for example "Add retry to the upload client").
- If the change needs context, add a blank line and a short body that explains what changed and why, wrapped at 72 columns.
- Show the message and run
git commitonly after the user confirms.
Describe what the diff actually does, not what was intended. Keep one logical change per commit; if the subject needs the word "and", the commit is probably too big.