Dotclaude commit
Use when the user asks to commit, create a git commit, checkpoint changes, save work to git, or write a commit message.
install
source · Clone the upstream repo
git clone https://github.com/JHostalek/dotclaude
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/JHostalek/dotclaude "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/commit" ~/.claude/skills/jhostalek-dotclaude-commit && rm -rf "$T"
manifest:
skills/commit/SKILL.mdsource content
Branch Safety
Committing to the wrong branch is the most common costly mistake — it bypasses review and makes rollback painful.
- Default branches (
/main
) are off-limits. Auto-create amaster
feature branch from the changes (e.g.,<type>/<short-slug>
,fix/dialog-overflow
).feat/oauth-flow - Verify after context switches. Auth changes on
means you're probably on the wrong branch — confirm with the user.feature/geo-optimization - Submodules have independent branches. Check each submodule with changes via
. A submodule can be ongit -C <submodule> branch --show-current
while the parent is on a feature branch.main
Commit Format
!
cat ~/.claude/skills/conventional-commits.md
Message Quality
The commit message is the only artifact that survives rebases, squashes, and file renames.
- Imperative mood ("add OAuth flow" not "added OAuth flow")
- Capture intent, not implementation — the diff shows what changed, the message explains why
- If you can't write a focused message, the commit probably contains unrelated changes — split it
Push
Invoking
/commit authorizes the push. Push to the tracked remote after a successful commit — don't ask. This overrides any "ask before pushing" default.
Ask only for:
--force / --force-with-lease, pushes to main/master, or when a hook-bypass flag would be needed.