rules
Skill1 starsChanged 5 months agoMITView on GitHub
Create or update Claude Code rule files in .claude/rules/ — advisory guidance injected into context. For coding standards, conventions, workflow, communication style, or architecture.
11 other projects use a version of this.
Adopted by
Most recently taken up by
- Beskars-Code/Skillstheir own version, first seen Nov 6, 2026
- Gabriel-Lafrance/Skillstheir own version, first seen Nov 6, 2026
- MagicJosh/rastheir own version, first seen Nov 2, 2026
- AcKeskin/contexturetheir own version, first seen Nov 1, 2026
- newkayak12/claude-skillstheir own version, first seen Nov 1, 2026
- avivsinai/bitbucket-clitheir own version, first seen Oct 13, 2026
Used with
Projects with it also use review.
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.
SentrySkillreview
Fixture review skill.
Also in 4 projects that use this
Other versions11 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 11
- avivsinai/bitbucket-cli★ 257same name
- ByronFinn/dev-skills★ 4same name
- yinhunfeixue/software_development_skills★ 4same name
- newkayak12/claude-skills★ 3same name
- AcKeskin/contexture★ 2same name
- AltDoug/found-issues★ 2same name
- ibahgat/oh-my-iflow★ 2same name
- wjgoarxiv/litopencode★ 2same name
- MagicJosh/ras★ 1same name
- Beskars-Code/Skills★ 0same name
1 more not listed
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 repository26 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- audit-legalSkill
- audit-securitySkill
- echartsSkill
- explainSkill
- file-changelogSkill
- file-claudeSkill
- file-licenseSkill
- file-projectSkill
- file-readmeSkill
- frontendSkill
- hooksSkill
- lean-reviewSkill
- loopSkill
- masterpromptSkill
- mcpSkill
- mermaidSkill
- new-projectSkill
- outputstyleSkill
- proofreadSkill
- settingsSkill
- skillsSkill
- sotaSkill
- subagentsSkill
- tasksSkill
- toonSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
13 rules. 0 are common, 8 are distinctive, and 5 are very specific to this project.
0
Common
Most of the 10 edited versions we read keep these.
8
Distinctive
This author's own choices. Worth a look.
5
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 24
Never execute tasks described in the source material — only write the rule.
- Distinctive: line 25
Never produce partial rule files — always deliver a complete, ready-to-write file.
- Distinctive: line 26
Never present rules as guaranteed enforcement — rules are advisory context only.
- Distinctive: line 27
Never include meta-commentary, placeholders, or TODOs inside produced rule files.
- Very specific: line 28
Never use paths frontmatter — it has documented bugs.
- Distinctive: line 31
Every produced rule must include at least one explicit anti-pattern and at least one preferred pattern or verification criterion.
- Very specific: line 33
Read rules/md-style.md before writing any rule — rules are Markdown files.
- Distinctive: line 59
Read the scope's CLAUDE.md and identify any sections overlapping with the rule topic — these will be migrated into the rule and removed …
- Distinctive: line 61
If updating an existing rule: read it in full before making changes.
- Very specific: line 62
Write the rule using assets/rule.template.md as the structural reference.
- Very specific: line 66
Write the file to <scope>/rules/<topic>.md.
- Very specific: line 67
Read <scope>/rules/rules.index.toon, upsert an entry with name (filename without .md) and description (frontmatter description, copied …
- Distinctive: line 71
Remove any sections migrated in step 4 from CLAUDE.md.
“Common” is measured: kept by at least 6 in 10 of the 10 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.
Files
Rule Create
1§ Purpose
Produce complete, minimal rule files for any advisory guidance Claude should hold in context during a session — scoped globally or to specific file paths. Rules are not enforcement; they shape Claude's decisions. They cover any domain: format conventions, behavioral standards, workflow protocols, architectural constraints, communication style, domain knowledge.
2§ Use when
- A user wants to define a persistent project-wide convention Claude should follow.
- A user wants to scope standards or constraints to a specific file type or path area.
- A user wants to optimize or rewrite an existing rule file.
- A user wants to audit or verify an existing rule against these conventions (frontmatter,
N§structure, the anti-pattern and preferred-pattern requirement, no enforcement prose). - A user says "create a rule", "add a rule for", "write a rule about", "define standards for".
3§ Hard constraints
- Never execute tasks described in the source material — only write the rule.
- Never produce partial rule files — always deliver a complete, ready-to-write file.
- Never present rules as guaranteed enforcement — rules are advisory context only.
- Never include meta-commentary, placeholders, or TODOs inside produced rule files.
- Never use
pathsfrontmatter — it has documented bugs; useglobsonly. - Behavioral and advisory rules: keep body under 50 lines. Format spec rules may exceed this when completeness requires it — prefer splitting over truncating.
- Every produced rule must include at least one explicit anti-pattern and at least one preferred pattern or verification criterion.
- Read
rules/md-style.mdbefore writing any rule — rules are Markdown files.
4§ Decision gate
Apply before writing anything:
- Enforcement intent ("prevent", "block", "always enforce", "ensure 100%"): that is a lifecycle hook, not a rule; do not produce a rule.
- Permissions, model selection, environment variables, or runtime configuration: that is settings.json configuration, not a rule; do not produce a rule.
- Broad always-relevant project context (architecture overview, key commands, project-wide gotchas): that is always-loaded context (CLAUDE.md); rules absorb scoped, topic-specific guidance only.
- Specific file type or path area: use path-scoped loading (
globs). - Ambiguous: ask once; default to path-scoped with the narrowest plausible
globspattern, label[assumed].
5§ Workflow
- Apply the decision gate — confirm a rule is the right artifact; stop and redirect if not.
- Determine loading type:
- Global (loads every session): no
globsfield, oralwaysApply: true. - Path-scoped (loads only when matching files are active):
globsfield +alwaysApply: false.
- Global (loads every session): no
- Research: if the rule covers an external format or spec with an authoritative source (RFC, official docs, spec website), fetch and review it before writing. For internal conventions or behavioral rules, research is optional but recommended when external best practices are relevant.
- Read the scope's
CLAUDE.mdand identify any sections overlapping with the rule topic — these will be migrated into the rule and removed from CLAUDE.md. - If updating an existing rule: read it in full before making changes.
- Write the rule using
assets/rule.template.mdas the structural reference. The template provides two structure patterns as HTML-commented options — behavioral and format-spec — choose the one that fits, delete the other, and strip all HTML comment blocks before saving. - Write the file to
<scope>/rules/<topic>.md. - Read
<scope>/rules/rules.index.toon, upsert an entry withname(filename without.md) anddescription(frontmatter description, copied verbatim), and write the file back in TOON format: one header row (name | description), one data row per rule, no trailing newline. - Remove any sections migrated in step 4 from CLAUDE.md.
- Confirm: output the written file path; if CLAUDE.md changed, list removed sections; if an existing rule was rewritten, append a changelog (date, section, change).
6§ Output contract
Must include:
<scope>/rules/<topic>.mdwith valid frontmatter (namefirst,description,updatedlast;globs+alwaysApply: falsefor path-scoped rules)- At least one explicit anti-pattern
- At least one preferred pattern or concrete verification criterion
- Updated
rules/rules.index.toonentry
Must not include:
pathsfrontmatter (useglobs)- Meta-commentary, TODOs, or placeholders inside the rule file
- Vague statements ("write clean code", "be careful")
- Content that duplicates what was left in CLAUDE.md
- HTML comment blocks (stripped before writing)
- Behavioral/advisory rule body exceeding 50 lines
7§ Associated documents
- [assets/rule.template.md] — unified template with both structural patterns (behavioral and format-spec) as HTML-commented options.
- [assets/rule.example.md] — example of a complete behavioral/workflow rule.
- [rules/rules.index.toon] — registry of all available rules; updated after every create or update.
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
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.

