agentleFS
leekleek/agent-skills/skills/commit/SKILL.md

commit

Skill3 starsChanged 2 months agoMITView on GitHub

Commit the work done in this session, skipping files a parallel session also touched.

193 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use create-branch, review-r 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.
  • SentrySkill

    create-branch

    Create a git branch following Sentry naming conventions. Use when asked to "create a branch", "new branch", "start a branch", "make a branch", "switch to a new branch", or when starting new work on the default branch.

    Also in 4 projects that use this

  • luischanciSkill

    review-r

    Run the R code review protocol on R scripts. Checks code quality, reproducibility, domain correctness, and professional standards. Produces a report without editing files.

    Also in 3 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

  • 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

  • AWSSkill

    issue

    Implement a GitHub issue end-to-end — branch, code, test, docs, and commit.

    Also in 9 projects that use this

  • luischanciSkill

    validate-bib

    Validate bibliography entries against citations in all manuscript files. Find missing entries and unused references.

    Also in 3 projects that use this

  • +2 more from luischanci

The file

We split this skill into the rules it gives an agent

6 rules. 0 are common, 5 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 174 edited versions we read keep these.

  • 5

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Commit only what you changed in this session.

    line 12
  2. Distinctive:

    Check the tree: Run git status --porcelain.

    line 19
  3. Very specific:

    Commit by path, without touching the index: Use git commit --only -m "<subject>" -- <path> <path> … (options before the --).

    line 26
  4. Distinctive:

    Commit to the current branch, whatever it is: Never switch, create, or suggest a branch, not even when the current branch is main/master.

    line 43
  5. Distinctive:

    If the changes are genuinely two unrelated things, make two commits, still your files only.

    line 46
  6. Distinctive:

    Never git stash, git checkout --, or git reset: a parallel session's uncommitted work is unrecoverable if you discard it.

    line 47

“Common” is measured: kept by at least 6 in 10 of the 174 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

Commit only what you changed in this session. Other sessions may be working in the same repo at the same time; that is expected, and none of their work is yours to commit.

Process

  1. List your files. From this conversation, write down every file you created, edited, or deleted. If you touched nothing, say so and stop.
  2. Check the tree. Run git status --porcelain. Anything not on your list belongs to someone else, ignore it completely.
  3. Drop the overlaps. For each of your files, git diff -- <path> (git diff --cached too if it is already staged). If it contains changes you did not make, leave that file out, the other session will commit it. If a file mixes your hunks with foreign hunks, stage only yours with git add -p -- <path>; never include a foreign hunk because it is small. Note which files you skipped.
  4. Commit by path, without touching the index. Use git commit --only -m "<subject>" -- <path> <path> … (options before the --). --only commits exactly the named paths and ignores whatever another session has already staged, so a foreign git add can never ride along. Never git add -A, git add ., or commit -a. For a partially staged file from step 3, git commit -m "<subject>" -- <path> after git add -p instead. New files are the exception: --only silently skips untracked paths, so git add -- <new-path> each file you created first, then include it in the same --only list. Check git status --porcelain afterwards; a ?? line for one of your files means it was skipped.
  5. Subject. Conventional Commits: type(scope): summary: imperative mood, lowercase, no trailing period, under 72 chars. Types: feat, fix, refactor, docs, test, chore, perf, build, ci. Scope optional. Add a short body only when why is not obvious from the diff. No attribution or co-author trailers.
  6. Report. One line: the commit subject, the short SHA, and any files you deliberately left out and why. Do not push unless asked.

Guardrails

  • Commit to the current branch, whatever it is. Never switch, create, or suggest a branch, not even when the current branch is main/master. No git checkout, git switch, git branch.
  • One session's work, one commit. Do not amend, rebase, or touch existing history.
  • If the changes are genuinely two unrelated things, make two commits, still your files only.
  • Never git stash, git checkout --, or git reset: a parallel session's uncommitted work is unrecoverable if you discard it.
  • Need a pre-change baseline of a file? Copy it aside and git show HEAD:<path> > <path>, run what you need, then restore the copy. A scoped stash plus immediate pop is still a stash.

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.