agentleFS
sh4wty1sh4wty1/fassi-skills/skills/write-commit/SKILL.md

write-commit

Skill2 starsChanged 36 days agoMITView on GitHub

Write a git commit message in the convention the repository already uses, then commit the staged changes once the user approves. Use whenever you are about to create a commit or are asked for a commit message.

  • Commits and pushes

4 other projects use a version of this.

Adopted by

Most recently taken up by

  • Other versions4 projects use a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 4

    1. adhamhaithameid/write-skills★ 1same name
    2. matheusPavaneli/workbench★ 1same name
    3. openjck/agent-skills★ 0same name
    4. ZAidBinAsif/flutter-ai-starter★ 0same name

    How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.

  • In this repository2 other files it gives its agents.

The file

We split this skill into the rules it gives an agent

4 rules. 0 are common, 3 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 4 edited versions we read keep these.

  • 3

    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
  • could be automatic: a setting could enforce it
  1. Distinctive:

    Write the message for the staged changes in the repository's own convention, and commit once the user approves.

    line 6
  2. Distinctive:

    Body: only when the reason is not obvious from the diff.

    line 44
  3. Distinctive:

    Add the trailers the repo's rules or your own instructions require, and no others.

    line 58
  4. Very specific:

    Leave these to an explicit request: staging everything (git add -A, git add .), --amend, --no-verify and git push.

    line 60

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

Write the message for the staged changes in the repository's own convention, and commit once the user approves.

1. Find the convention

The first of these that exists wins:

  1. Written rules: a commitlint config (commitlint.config.*, .commitlintrc*, a commitlint key in package.json), or a section on commits in CONTRIBUTING*, AGENTS.md or CLAUDE.md.
  2. History: the subjects of git log -20 --no-merges --format=%s. When most of them share a format, follow it in every respect: prefix or none, language, capitalisation, tense, length.
  3. Fallback: with fewer than 5 commits, or no format that most of them share, use the fallback below.

2. Fallback convention

Conventional Commits, in English:

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

<body>

<footer>
TypeFor
featNew behaviour for the user
fixA bug corrected
docsDocumentation only
refactorCode restructured, behaviour unchanged
testTests added or corrected
perfSame behaviour, faster or lighter
buildBuild system or dependencies
ciCI configuration
choreMaintenance that fits no other type
revertA previous commit undone
  • Scope: optional, the module touched, when the repo has clear modules.
  • Breaking change: ! before the colon, plus a BREAKING CHANGE: footer saying what breaks.
  • Subject: imperative, lower-case start, no final period, at most 72 characters counting the prefix.
  • Body: only when the reason is not obvious from the diff. It says why, wrapped at 72 columns.
  • No emoji.

3. Read the staged changes

Read git diff --staged.

  • Nothing staged: list the changed files from git status --short and ask which ones enter. Stage only the files the user names.
  • Unrelated changes staged together (the subject would need an "and"): say so and propose the split, with the files and the message of each commit. Split only when the user accepts; otherwise write one commit.

4. Propose, then commit

Show the message in a code block, with one line saying which convention it follows and where that came from (the rules file, the history, or the fallback). Commit when the user approves, after applying any change they ask for. An instruction to commit without asking, given earlier in the session, counts as approval.

Add the trailers the repo's rules or your own instructions require, and no others.

Leave these to an explicit request: staging everything (git add -A, git add .), --amend, --no-verify and git push. When a hook rejects the commit, report its output and fix the cause.

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.