agentleFS
arumaekawaarumaekawa/codex-skills/skills/tidy-first/SKILL.md

tidy-first

Skill4 starsChanged 4 months agoMITView on GitHub

Inspect existing code against an accepted implementation design and apply only small, behavior-preserving structural tidies that make the upcoming behavior change safer or clearer. Use before implementing a behavior change in existing code when a concrete design exists.

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

10 rules. About 0 are common, 10 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈10

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Prefer no tidy when the behavior change can be implemented clearly and safely as-is.

    line 14
  2. Distinctive:

    Treat broad redesigns, public interface changes, migrations, and cross-system refactors as design work rather than tidies.

    line 15
  3. Distinctive:

    Keep the tidy separate and independently reviewable from the upcoming behavior change.

    line 21
  4. Distinctive:

    Verify preserved behavior with focused checks when practical.

    line 22
  5. Distinctive:

    Stop when the accepted design can be implemented directly.

    line 23
  6. Distinctive:

    Do not implement the requested behavior change.

    line 27
  7. Distinctive:

    Do not change observable behavior, interfaces, persisted data, errors, logging semantics, validation, authorization, or compatibility …

    line 28
  8. Distinctive:

    Do not perform unrelated cleanup, speculative abstraction, or broad refactoring.

    line 29
  9. Distinctive:

    Do not continue tidying after the immediate obstacle has been removed.

    line 30
  10. Distinctive:

    If behavior preservation is uncertain, stop and report the uncertainty instead of treating the change as a tidy.

    line 31

≈ “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

Tidy First

Inspect the existing implementation against the accepted design before changing behavior. Apply a tidy only when a specific structural obstacle makes the planned change harder to implement, verify, or review.

Decide Whether to Tidy

  • Identify structural obstacles directly relevant to the accepted design.
  • Tidy first only when a small, local change will reduce immediate implementation risk or complexity.
  • Prefer no tidy when the behavior change can be implemented clearly and safely as-is.
  • Treat broad redesigns, public interface changes, migrations, and cross-system refactors as design work rather than tidies.

Apply the Tidy

  1. Identify the smallest behavior-preserving change that removes the obstacle.
  2. Apply one focused structural change at a time.
  3. Keep the tidy separate and independently reviewable from the upcoming behavior change.
  4. Verify preserved behavior with focused checks when practical.
  5. Stop when the accepted design can be implemented directly.

Guardrails

  • Do not implement the requested behavior change.
  • Do not change observable behavior, interfaces, persisted data, errors, logging semantics, validation, authorization, or compatibility requirements.
  • Do not perform unrelated cleanup, speculative abstraction, or broad refactoring.
  • Do not continue tidying after the immediate obstacle has been removed.
  • If behavior preservation is uncertain, stop and report the uncertainty instead of treating the change as a tidy.

Report the Result

Record or return the tidy decision, changes, verification results, and material discoveries as directed by the caller:

  • Decision: Tidy applied or no tidy needed.
  • Changes: The structural changes made.
  • Verification: The checks performed and their results.
  • Discoveries: Any relevant constraint, risk, or design issue found during the tidy.

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.