# Commit

> Create a well-formatted conventional commit with proper message

- Skill: `martinacostadev/commit` (Agent Skill)
- Install (CLI): `npx skillmds@latest add martinacostadev/commit`
- Raw SKILL.md: https://api.skillmd.com/api/skills/martinacostadev/commit/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: martinacostadev (https://skillmd.com/u/martinacostadev)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/martinacostadev/commit

---


Create a git commit following conventional commits specification.

## Commit Types
- `feat`: New feature
- `fix`: Bug fix
- `refactor`: Code refactoring
- `test`: Adding tests
- `docs`: Documentation
- `style`: Formatting (no code change)
- `perf`: Performance improvement
- `chore`: Maintenance tasks

## Process

1. Run `git status` to see changes
2. Run `git diff --staged` to review staged changes
3. If no staged changes, suggest files to stage
4. Generate commit message based on changes:
   - Use conventional commit format: `type(scope): description`
   - Keep subject line under 72 characters
   - Use imperative mood ("add" not "added")
   - Include body for complex changes

## Commit Message Format

```
type(scope): short description

[optional body with more details]

[optional footer with breaking changes or issue references]
```

## Examples

```bash
# Feature
git commit -m "feat(auth): add OAuth2 login with Google provider"

# Bug fix
git commit -m "fix(api): handle null response from external service"

# Refactor
git commit -m "refactor(hooks): extract useAuth logic into separate hook"
```

If argument provided: $ARGUMENTS

