agentleFS
Sequela02Sequela02/canasta/skills/workflow/repository-text-hygiene/SKILL.md

repository-text-hygiene

Skill0 starsChanged yesterdayMITView on GitHub

Diagnose and repair Git, encoding, line-ending, formatter, or

  • Deletes or force-pushes

The file

We split this skill into the rules it gives an agent

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

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈1

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Keep encoding and line-ending policy in repository configuration.

    line 26
  2. Very specific:

    Verify remaining status against actual diffs and intentional untracked files, inspect staged changes, and recheck representative bytes and …

    line 37
  3. Very specific:

    Use documentation-hygiene for document ownership and lifecycle.

    line 43

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

Repository Text Hygiene

Establish the cause of text drift before modifying files or configuration.

  1. Inspect repository guidance, .gitattributes, .editorconfig, formatter rules, hooks, and CI. Inspect only relevant Git settings and their origins; avoid dumping unrelated configuration that may contain credentials. Compare status, unstaged and staged diffs, and numstat; inspect attributes for representative paths. A large status count does not authorize normalization.
  2. Separate real edits, intentional generated changes, line-ending differences, and index/stat noise. Compare a suspicious path's index blob with its filtered working-tree hash, using git hash-object --path for that same path. Equality supports refreshing that path's index metadata; it does not prove the entire worktree is safe to stage. Preserve staged/unstaged boundaries and user work.
  3. Keep encoding and line-ending policy in repository configuration. Prefer UTF-8 without BOM and LF for text when establishing a policy, but inspect platform entry points, binary files, raw-byte fixtures, and digest contracts first. Respect required exceptions. Align editor, formatter, and Git attributes rather than repeatedly rewriting files or changing global Git defaults. Use non-mutating CI checks and explicit formatter application.
  4. Repair only diagnosed paths within scope. Never use git reset --hard, broad checkout/restore, or git clean to clear status noise. Refresh the index only for individually verified byte-equivalent paths. Reserve bulk renormalization for an isolated change with unrelated work preserved, reviewed attributes, and the complete normalization diff inspected. Do not stage unrelated changes.
  5. Verify remaining status against actual diffs and intentional untracked files, inspect staged changes, and recheck representative bytes and attributes. Run git diff --check, applicable formatter checks, and affected build or digest checks. Refresh the IDE view if it still disagrees with Git; report unresolved discrepancies rather than rewriting files to make the display quiet.

Use documentation-hygiene for document ownership and lifecycle. This procedure does not choose a repository's language, directory layout, release policy, or global tool configuration.

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.