Slash command

/commit

Stages and commits with a clean conventional-commit message generated from the actual diff — no "update files" commits.

gitcommitworkflow
Install to
~/.claude/commands/commit.md
descriptionReview the staged + unstaged changes and create a well-formed commit.

Look at the current changes and create a commit:

  1. Run git status and git diff (staged and unstaged) to see what changed.
  2. Run git log --oneline -10 to match this repo’s message style.
  3. Stage the relevant files by name (never git add -A blindly — skip .env, build artifacts, anything that looks like a secret).
  4. Write a concise message: a type(scope): summary subject line under ~70 chars, then a body explaining the WHY if it isn’t obvious.
  5. Commit. Do NOT push unless I ask.

If there are no changes, say so — don’t create an empty commit.

How to install

  1. Copy the code and save it to ~/.claude/commands/commit.md (user) or .claude/commands/commit.md (project).
  2. Commands hot-reload — it's available in the current session immediately.
  3. Run it by typing /commit in the prompt.
  4. Verify: type / and look for it in the command list.

← More slash commands