# commit-smart

This skill reads Git changes, suggests a commit type and scope, then drafts a message that explains the reason behind the work. Use it when a diff alone would leave the intent unclear.

- skill · `type=skill` · Claude Code · 205 installs
- Author: davila7
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/davila7/claude-code-templates/tree/HEAD/cli-tool/components/skills/git/commit-smart
- Updated: 2026-10-24
- HTML: https://affpapa.org/en/nevibecode/skills/commit-smart

## What it does

The skill checks the working tree and inspects the staged diff to choose a commit type and scope. If nothing is staged, it lists changed files, proposes a logical group, and asks what should go into the index. You can override the detected type or scope with arguments such as `fix` or `refactor api`.

Before writing anything to Git history, it presents the proposed message and waits for approval. The subject uses a conventional commit format; for substantive changes, the body gives the motivation rather than restating the diff. After approval, the skill runs `git commit` and checks the latest entry with `git log`. Your confirmation is required before the commit is created.

## Install

### Claude Code (native platform)

1. **claude-code-templates**
```bash
npx claude-code-templates@latest --skill git/commit-smart
```

2. **Skills CLI (Vercel)**
```bash
npx skills add davila7/claude-code-templates --skill commit-smart -a claude-code
```

3. **Manually: put the files in place**
- File: `~/.claude/skills/commit-smart/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/commit-smart/

### Codex

**Manually: put the files in place**
- File: `.agents/skills/commit-smart/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

**Manually: put the files in place**
- File: `.cursor/skills/commit-smart/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install davila7/claude-code-templates commit-smart
```

2. **Manually: put the files in place**
- File: `.github/skills/commit-smart/SKILL.md`

### Gemini CLI

**Platform CLI**
```bash
gemini skills install https://github.com/davila7/claude-code-templates --path cli-tool/components/skills/git/commit-smart
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/commit-smart/SKILL.md` — The legacy .windsurf/skills/ path still works

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/davila7/claude-code-templates/tree/HEAD/cli-tool/components/skills/git/commit-smart

## When to use it
- infer a commit type from a diff
- choose a scope from the affected module
- group unstaged files before adding them
- write a commit message that explains the reason
- verify the latest commit in Git history

## Example prompts
- Review my current Git changes and suggest which files belong in one commit.
- Use `fix` as the commit type and explain the reason in the message.
- Create a `refactor api` commit message and wait for my approval before committing.

## Similar
- [triage](https://affpapa.org/en/nevibecode/skills/triage.md) — skill · 990453 installs
- [code-review](https://affpapa.org/en/nevibecode/skills/code-review.md) — skill · 789521 installs
- [implement](https://affpapa.org/en/nevibecode/skills/implement.md) — skill · 774700 installs
- [git-guardrails-claude-code](https://affpapa.org/en/nevibecode/skills/git-guardrails-claude-code.md) — skill · 499069 installs
- [setup-pre-commit](https://affpapa.org/en/nevibecode/skills/setup-pre-commit.md) — skill · 489289 installs
- [scaffold-exercises](https://affpapa.org/en/nevibecode/skills/scaffold-exercises.md) — skill · 480196 installs

From the same set: [davila7/claude-code-templates](https://affpapa.org/en/nevibecode/by/davila7/claude-code-templates.md) — 495 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
