Index of every page on this site: llms.txt
All skills
ccusage avatar

/commit

@7e789e8
by ccusageccusage/ccusage20k stars
934
Run it yourself

Creates atomic Conventional Commits. Use when committing code changes, splitting a diff into independently revertable hunks, staging precise patches non-interactively, or writing commit messages.

Use this Skill: https://skilld.dev/gh/ccusage/ccusage/commit

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

SKILL.md

≈51 tokens for metadata: the name and description. ≈653 when used: this file. ≈243 more on demand in 2 files.

Description uses 2.5% of example budget

Before choosing a Skill, your Agent reads its name and description. All available Skills share that space.

  • A shorter description leaves more room for other Skills. This entry exceeds our 1% size suggestion.

In our Claude Code example, all Skill names and descriptions share 8,000 characters. This Skill uses ≈204 characters, or 2.5%.

The 1% threshold is a size suggestion. Longer descriptions can still fit.

Your model, settings, and other Skills decide how much text your Agent can read.

Example settings and source

The example uses a 200k-token context and default Claude Code settings. The count includes the name, description, separators, and when_to_use when present. Codex also counts local file paths.

Skit's source and limits: Codex 0.160.1, Claude Code 2.1.292.

Commit

Arguments:

  • push: push after committing (default: false).

Workflow

  1. Read the state and recent history — git status --short, git diff HEAD, git log --oneline -10 — and match the granularity, scopes, and explanation style already in the log.
  2. Split the diff into independently revertable units, hunk by hunk rather than file by file.
  3. Stage each unit with git apply --cached -v <patch>. git add -p and git add --interactive hang in this environment, so a patch is the only way to stage part of a file. Read references/git-apply.md when one fails to apply.
  4. Commit, then confirm with git show HEAD.

Reversibility

Every commit answers "if I revert this alone, does anything else break?". Tiny commits are expected: one review comment, one wording correction, one reference-file extraction.

Tiny is not partial. A move, rename, or extraction lands as a single commit holding both sides — old path removed, new path added, references updated, generated links synced.

Keep separate concerns in separate commits even when each change is correct, so reverting one concern does not revert unrelated work.

PR branches are squash-merged, so review fixes stack as follow-up commits. Amend only unpublished local mistakes, or when the user asks.

Messages

The subject names the artifact or behavior changed and reads sensibly alone in a commit list; reviewer context goes in the body. Prefer docs(skills): clarify reference routing with a body citing the CodeRabbit feedback over chore: address review feedback. The body wraps at 72 columns and covers problem, rationale, decisions, and impact.

The commit-msg hook runs scripts/validate-commit-scope.nu: when staged paths live under rust/adapters/<agent>/, the scope must be that agent (fix(kimi)), one of the cross-cutting scopes, or — for a change spanning several agents — a workspace scope. rust/adapters/common/ derives adapter, not common. Read the script for the current lists; no other part of the tree derives a scope.

Formatter-only changes are chore: format, or chore(<scope>): format when the scope rule above applies. Messages are US English.

Push (push=true)

Changes reach main through a PR, so commit on a feature branch; references/push.md has the branch and upstream checks.

Push once every commit is in place and let the hooks in nix/git-hooks.nix run — treefmt and gitleaks on commit; treefmt, gitleaks, oxlint, clippy -D warnings, node test, and cargo test on push. Their failures are part of normal validation, so fix them in a new small commit.

Source: SKILL.md on GitHub

No rule matched.

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No alerts2mo3 checks · Risk SAFE
  • Gen Agent Trust Hub2mo

    The skill provides a workflow for creating granular, revertable git commits following the Conventional Commits specification. No security issues were detected.

  • Socket2mo

    No alerts

  • Snyk2mo

    Risk: LOW · No issues

Signed by skilld at 7e789e8. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub yesterday.

Activeupdated yesterday

README badge

README badge for ccusage/ccusage/commit