commit

Installation
SKILL.md
Contains Shell Commands

This skill contains shell command directives (!`command`) that may execute system commands. Review carefully before installing.

Git Commit

Pre-loaded context

  • Status: !git status
  • Diff: !git diff HEAD
  • Log: !git log --oneline -10

Message Style

Match repo's existing commit patterns from log.

  • Extreme concision, sacrifice grammar for brevity
  • Focus on "why" not "what"
  • Imperative mood

Workflow

  1. Review status and diff
  2. Analyze recent commit style from log
  3. Stage files explicitly (avoid git add . or -A)
  4. Commit with HEREDOC format matching repo style
  5. Run git status after to verify

Examples

Bug fix -- single file:

git add src/auth.ts
git commit -m "fix: null check in login handler"

Feature -- multiple related files:

git add src/components/SearchBar.tsx src/hooks/useSearch.ts
git commit -m "add search bar component"

Refactor -- extraction:

git add src/utils/validation.ts
git commit -m "extract email validation to util"

Rules

  • NEVER amend unless requested
  • NEVER skip hooks
  • NEVER commit secrets
  • Only commit when requested
  • Match existing commit patterns

Error Handling

  • Pre-commit hook fails -- fix issue, re-stage, create NEW commit (never --amend)
  • Nothing to commit -- report clean working tree and stop
  • Staged files contain secrets -- abort, warn user, unstage the file

See Also

Related skills

More from helderberto/skills

Installs
38
GitHub Stars
8
First Seen
Feb 13, 2026