agentleFS
DanaResearchGroupDanaResearchGroup/agent-skills/writing-git-commits/SKILL.md

writing-git-commits

Skill1 starsChanged 3 months agoMITView on GitHub

Use when committing, staging, or splitting changes into commits (or about to run `git commit`) — keeps commit messages short and readable, splits work into one logical unit per commit, and avoids destructive or unauthorized git actions.

  • Commits and pushes

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

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

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    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:

    No trailing period. No issue numbers in the subject unless asked.

    line 19
  2. Distinctive:

    Add a body only when the *why* is non-obvious.

    line 23
  3. Very specific:

    Never edit .git/config or alter the user's git identity.

    line 40

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “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

Writing Git Commits

Overview

This user prefers commit messages that read like log lines, not essays. Default to a single short subject; only add a body line when the why is non-obvious. The diff already shows the what.

Subject Line

  • Imperative, lowercase after the topic prefix, ≤ ~60 chars total.
  • Optional <topic>: prefix when the change is scoped to one area (e.g. scheduler:, ipython:, common:).
  • No trailing period. No issue numbers in the subject unless asked.

Body

  • Add a body only when the why is non-obvious. Keep it to one short line or a single tight paragraph; the diff already shows the what.
  • Wrap at ~72 chars.

Granularity

  • One logical change per commit. If the diff spans unrelated areas, split by git add <paths> into separate commits.
  • Group a helper and its tests into the same commit; group the consumer of that helper into the next commit.

Hard Don'ts

  • No git push unless the user explicitly asks.
  • No --amend on already-pushed commits, no force-push to main/master.
  • No --no-verify, --no-gpg-sign, or other hook/sign bypass flags.
  • No git add -A / git add . — stage explicit paths only.
  • Never edit .git/config or alter the user's git identity.

Examples

Good (one-line):

ipython: fix parser import in 1D torsion scan

Good (with brief body):

scheduler: snapshot running jobs to running_jobs.yml hourly

Append per-hour snapshot only when changed; otherwise emit a
one-line heartbeat in ARC.log.

Bad (verbose body restating the diff):

ipython: fix parser import in 1D torsion scan notebook

arc.parser is a package; import from arc.parser.parser.

The body restates what the subject already says — drop it.

Good (long is OK sometimes if necessary):

mapping/engine: two-pass pairing to reject formula-only matches

r_cut_p_cut_isomorphic matched purely on molecular-formula fingerprint OR
graph isomorphism, so constitutional isomers sharing a formula (e.g. the
alpha vs beta pentyl-ether radicals in H-abstraction between identical
donors) got paired as "isomorphic" and handed to map_two_species, which
then failed to superimpose them and returned None.

Add a strict flag that requires full graph isomorphism, and run
pairing_reactants_and_products_for_mapping in two passes: strict first,
then the loose fingerprint-or-isomorphic fallback for any unmatched
r-cuts so rearrangements whose cuts aren't strictly isomorphic (e.g.
Intra_Disproportionation, ring-openings) still work.

Also guard glue_maps against a None per-pair map so the caller sees a
clean None instead of a TypeError when a future mapping regression slips
through.

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.