agentleFS
LegendAppLegendApp/legend-skills/commit/SKILL.md

commit

Skill38 starsChanged 41 days agoMITView on GitHub

Commit the requested task changes, or plan their commits when review is requested. Include the whole tree only when explicitly asked.

188 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use validate-plan, act-on-feedback and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • shawn-dumasSkill

    validate-plan

    Validate an orchestration plan after pre-flight certification. Runs adversarial review, deep review (verify prompt data against codebase), and PoC gate for risky approaches. Auto-invoked by orchestrate-* skills at Step 8.

    Also in 5 projects that use this

  • MicrosoftSkill

    act-on-feedback

    Act on user feedback attached to the current session. Use when the user submits feedback on the session's changes via the Submit Feedback button.

    Also in 3 projects that use this

  • decocmsSkill

    add-mcp-tools

    Guide for adding new MCP tools with consistent patterns for schemas, tool definitions, registry updates, and Better Auth integration

    Also in 3 projects that use this

  • MicrosoftSkill

    generate-run-commands

    Generate or modify run commands for the current session. Use when the user wants to set up or update run commands that appear in the session's Run button.

    Also in 3 projects that use this

  • mitsuhikoSkill

    oebb-scotty

    Austrian rail travel planner (ÖBB Scotty). Use when planning train journeys in Austria, checking departures/arrivals at stations, or looking for service disruptions. Covers ÖBB trains, S-Bahn, regional trains, and connections to neighboring countries.

    Also in 3 projects that use this

  • mitsuhikoSkill

    pi-share

    Load and parse session transcripts from shittycodingagent.ai/buildwithpi.ai/buildwithpi.com/pi.dev (pi-share) URLs. Fetches gists, decodes embedded session data, and extracts conversation history.

    Also in 3 projects that use this

The file

Show its rules and text

We split this skill into the rules it gives an agent

19 rules. 0 are common, 15 are distinctive, and 4 are very specific to this project.

  • 0

    Common

    Most of the 168 edited versions we read keep these.

  • 15

    Distinctive

    This author's own choices. Worth a look.

  • 4

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use this skill to turn the requested changes into one or more clean commits without absorbing unrelated work.

    line 8
  2. Distinctive:

    Default: commit only changes made by the current agent in the current task.

    line 12
  3. Distinctive:

    If change ownership or the requested boundary cannot be determined reliably, stop before staging and ask.

    line 16
  4. Distinctive:

    Direct mode: If the user asks to commit, analyze the requested scope and create the needed commit or commits without asking for a separate …

    line 20
  5. Very specific:

    Approval response: If a previous turn presented a commit plan and the user now says go, treat that as approval for that plan.

    line 23
  6. Distinctive:

    Read repository guidance first: AGENTS.md, contribution docs, or visible commit conventions.

    line 27
  7. Distinctive:

    If there are no in-scope changes, say so and report any remaining out-of-scope changes without committing them.

    line 33
  8. Distinctive:

    If a file contains unrelated changes, split by hunk with git add -p or another path/hunk-limited staging method.

    line 39
  9. Distinctive:

    Follow explicit user instructions and repository or workspace guidance when present.

    line 43
  10. Very specific:

    when the commit fixes a verified GitHub issue, append #<number> to the end of the subject

    line 50
  11. Distinctive:

    Before accepting a subject:

    line 52
  12. Distinctive:

    Prefer naming the affected symbols or types over inventing an umbrella phrase.

    line 55
  13. Very specific:

    Avoid vague abstractions such as improve behavior, update handling, or compare collection values when the specific change can be named.

    line 57
  14. Very specific:

    Avoid scoped subjects (fix(list): ...) and vague summaries (update stuff).

    line 68
  15. Distinctive:

    Use a body for behavioral changes when the reason, invariant, or validation would not be obvious from the title.

    line 70
  16. Distinctive:

    When plan mode is active, present:

    line 74
  17. Distinctive:

    Verify the intended commit contains only that group with git diff --staged --stat, targeted git diff --staged, and git diff --staged …

    line 92
  18. Distinctive:

    Commit with the agreed message.

    line 93
  19. Distinctive:

    After all commits, report commit hashes and any remaining unstaged files.

    line 96

“Common” is measured: kept by at least 6 in 10 of the 168 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Commit

Use this skill to turn the requested changes into one or more clean commits without absorbing unrelated work.

Scope

  • Default: commit only changes made by the current agent in the current task. Determine ownership from the known starting state, conversation, and tool history; do not infer it merely from the current diff or file path.
  • All changes: inspect and commit the whole working tree only when the user explicitly asks to commit all, everything, or the whole tree.
  • Explicit subset: honor any files, hunks, commits, or exclusions named by the user.
  • Temporary artifacts: exclude investigation-only diagnostics, logs, traces, profiler output, experimental toggles, screenshots, and repro fixtures unless explicitly requested. Keep permanent regression tests; ask if unclear.
  • If change ownership or the requested boundary cannot be determined reliably, stop before staging and ask. Never include pre-existing, concurrent, or user-authored changes by guesswork.

Approval Modes

  • Direct mode: If the user asks to commit, analyze the requested scope and create the needed commit or commits without asking for a separate "go".
  • Plan mode: If the user asks for a plan, asks to review commits first, says to wait, says to prompt or ask before committing, or otherwise requests approval first, present a commit plan and wait for explicit approval such as go before staging or committing. After approval, create all agreed commits without asking again unless the working tree changes unexpectedly.
  • Clarification stop: In any mode, stop before committing if ownership is unclear, mixed hunks cannot be staged safely, repository guidance conflicts with the user's request, or the intended grouping is ambiguous enough that committing would risk losing user intent.
  • Approval response: If a previous turn presented a commit plan and the user now says go, treat that as approval for that plan. Re-check the working tree before staging.

Inspect

  1. Read repository guidance first: AGENTS.md, contribution docs, or visible commit conventions.
  2. Determine whether the work fixes a known GitHub issue from explicit user context, an approved issue/task document, a verified issue URL, or repository metadata. Do not infer an issue relationship from an incidental number alone.
  3. Inspect state with git status -sb, git diff --stat, git diff --staged --stat, and targeted git diff / git diff --staged. Inspect relevant untracked files before staging them.
  4. Classify staged, unstaged, and untracked changes as in or out of scope. Task ownership does not imply inclusion; classify task-created instrumentation and fixtures as permanent or temporary before staging. Treat the full tree as context, not as permission to commit it.
  5. Preserve out-of-scope staged changes. If scoped changes occupy fully owned paths, a path-limited commit may leave unrelated index entries intact; if scoped and unrelated hunks share a path or safe isolation is uncertain, stop and ask rather than unstaging or committing someone else's work.
  6. Respect explicit exclusions, such as debug logs or generated artifacts the user said not to commit. Leave excluded changes unstaged and report them afterward.
  7. If there are no in-scope changes, say so and report any remaining out-of-scope changes without committing them.

Group

Group the in-scope changes by one coherent concept: feature, fix, refactor, test, docs, config, dependency, or subsystem. Prefer separate commits when changes would be reviewed, reverted, or explained independently.

If a file contains unrelated changes, split by hunk with git add -p or another path/hunk-limited staging method. Do not put unrelated hunks in one commit just because they share a file.

Message Style

Follow explicit user instructions and repository or workspace guidance when present; they override this skill's defaults. Otherwise use this default:

  • Conventional Commit type: subject
  • no scope parentheses
  • imperative, concrete subject
  • no trailing period
  • no Co-authored-by trailer unless the user explicitly asks
  • when the commit fixes a verified GitHub issue, append #<number> to the end of the subject

Before accepting a subject:

  • Name the concrete behavior and target using terminology visible in the diff, such as a function, API, type, or user-facing effect.
  • Prefer naming the affected symbols or types over inventing an umbrella phrase. Make the subject searchable in git log.
  • Reject a subject that could plausibly describe several unrelated diffs. Ask: "Would this explain what changed without opening the diff?"
  • Avoid vague abstractions such as improve behavior, update handling, or compare collection values when the specific change can be named.

Use the issue suffix only when the commit is intended to fix that issue, not merely when it is related or discovered during investigation. For multiple explicitly fixed issues, append each verified reference at the end. Repository-specific message rules or explicit user instructions still take precedence.

Examples:

fix: preserve scroll offset after prepend
fix: preserve failed CRUD creates #547

Avoid scoped subjects (fix(list): ...) and vague summaries (update stuff).

Use a body for behavioral changes when the reason, invariant, or validation would not be obvious from the title.

Plan Output

When plan mode is active, present:

Proposed commits (N):
1. type: concrete subject
   Rationale: Why this group belongs together.
   Files: path/a, path/b

Then ask for go or edits. Do not stage or commit until the user approves.

In direct mode, do this planning internally. Only show a concise summary before or while committing if it helps the user follow a multi-commit split.

Commit

For each group:

  1. Stage only that group using path-limited or hunk-limited staging. Do not silently unstage out-of-scope changes.
  2. Verify the intended commit contains only that group with git diff --staged --stat, targeted git diff --staged, and git diff --staged --check. When unrelated index entries remain, use a path-limited commit only for fully owned paths and verify those paths separately.
  3. Commit with the agreed message.
  4. Re-check the tree after hooks run, then continue to the next group; if a pre-commit hook runs checks broader than the repo's documented scoped checks, use the repo's documented way to scope or skip it and say so.

After all commits, report commit hashes and any remaining unstaged files. If a commit fails, stop and report the exact failure and the current git state.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.