AGENT SKILL

caveman-commit

Use when the user asks for a commit message, wants a Conventional Commit, or wants a terse commit subject that fits in fifty characters and focuses on why over what.

License 许可
MIT
最近更新
2026-11-09
Stars
★ 6
Forks
1

01 前言 Front Matter

name
caveman-commit
license
MIT
metadata
{ "author": "ai-playbook (ported from JuliusBrussee/caveman, MIT)", "version": "1.0" }
description
Use when the user asks for a commit message, wants a Conventional Commit, or wants a terse commit subject that fits in fifty characters and focuses on why over what.

03 SKILL.md 正文

caveman-commit — terse Conventional Commit messages

Write commit messages that are short, conventional, and focused on intent.

When to fire

User intent triggers (any of):

  • "/caveman-commit"
  • "write the commit message", "draft a commit", "commit this"
  • "give me a Conventional Commit"

Output contract

Always emit a Conventional Commit. Shape:

<type>(<scope>): <subject>

<body — optional, only if subject does not capture the why>

Rules:

  • <type> ∈ feat | fix | refactor | perf | docs | test | chore | build | ci | style.
  • <scope> ≤ 14 chars, kebab-case, optional. Drop the parentheses if no scope.
  • <subject> ≤ 50 chars, lowercase, no trailing period. Imperative voice ("add", not "added"/"adds").
  • <body> only when the subject cannot fit the why. Wrap at 72 chars. Caveman style: drop articles, fragments OK.
  • No "Generated with Claude" footer unless the user explicitly asks for it.
  • No emoji in subject. Body may use them sparingly if the user's repo style allows.

Steps

  1. Read the diff. Run git diff --cached (staged) or git diff (unstaged) — whichever the user pointed at. If both are empty, refuse with Nothing staged or modified to commit.

  2. Identify intent. What is the user trying to accomplish? Look at:

    • Added/removed lines, not just file count.
    • Renamed identifiers vs new logic vs deleted code.
    • Whether tests changed alongside production code.
  3. Pick the type.

    • New user-visible behavior → feat.
    • Bug fix → fix.
    • Internal restructure, no behavior change → refactor.
    • Performance improvement → perf.
    • Documentation only → docs.
    • Tests only → test.
    • Build/CI/deps → build/ci/chore.
  4. Pick the scope. Usually a directory or module name from the changed paths. Drop if scope spans multiple unrelated areas.

  5. Write the subject — why over what.

    • Bad: fix(auth): change <to<= in token expiry check
    • Good: fix(auth): close one-second token expiry gap
    • Bad: feat: add new endpoint
    • Good: feat(api): support batch user lookup
  6. Add a body only if needed. If the subject explains the why, skip the body. Otherwise add a 1-2 sentence caveman-style paragraph.

Trust boundary

  • Never commit the message. The skill drafts it; the user runs git commit.
  • Never include secrets, tokens, file contents from .env, or large diffs in the body.
  • If the diff is empty, refuse — do not invent intent.

Examples

feat(toggle): per-project caveman state at .ai-playbook/caveman.json
fix(mcp): guard against missing caveman-shrink binary

npx caveman-shrink absent on offline machines. Wrap call in
try/except, warn once, fall through to un-wrapped command.
refactor(scripts): single source of truth for skill descriptions

See also

04 同仓库更多 Skills

Wizarck
Wizarck/ai-playbook

sweep

Use when the user wants to find code that has quietly stopped being used — types /sweep, asks for a "dead code sweep", "repo entropy", "what can we delete", "orphan files", "unused code", or asks to review a sweep ledger. Adjudicates candidates a deterministic scanner already produced; it never deletes anything and never re-derives findings from raw source. Pairs with ponytail, which gates what gets written rather than what rots.

★ 6
Wizarck
Wizarck/ai-playbook

ponytail

Use when the user wants the laziest solution that actually works — types /ponytail, says "be lazy", "lazy mode", "simplest solution", "minimal solution", "yagni", "do less", or "shortest path", or complains about over-engineering, bloat, boilerplate, or unnecessary dependencies. Supports intensity levels lite, full, ultra (default). Pairs with caveman, which compresses prose, not code.

★ 6
Wizarck
Wizarck/ai-playbook

ponytail-review

Use when the user wants a code review focused exclusively on over-engineering — says "review for over-engineering", "what can we delete", "is this over-engineered", "simplify review", or invokes /ponytail-review. Complements correctness/security review; this one only hunts complexity in the current diff. Gated by the ponytail review_ponytail component.

代码审查
★ 6
Wizarck
Wizarck/ai-playbook

ponytail-debt

Use when the user wants to harvest every `ponytail:` comment in the codebase into a tracked debt ledger — says "ponytail debt", "/ponytail-debt", "what did ponytail defer", "list the shortcuts", "ponytail ledger", or "what did we mark to do later". One-shot report, changes nothing. Gated by the ponytail debt_ponytail component.

★ 6
Wizarck
Wizarck/ai-playbook

ponytail-audit

Use when the user wants a whole-repo audit for over-engineering — says "audit this codebase", "audit for over-engineering", "what can I delete from this repo", "find bloat", or invokes /ponytail-audit. Like ponytail-review but scans the entire tree, not a diff. One-shot report, applies no fixes. Gated by the ponytail audit_ponytail component.

★ 6
Wizarck
Wizarck/ai-playbook

openspec-propose

Propose a new change with all artifacts generated in one step. Use when the user wants to quickly describe what they want to build and get a complete proposal with design, specs, and tasks ready for implementation.

★ 6