agentleFS
y-miyazakiy-miyazaki/config/.cursor/rules/instructions.mdc

config / rules

Cursor rule1 starsChanged 8 days agoApache-2.0View on GitHub

Writing Instruction Files Instructions

The file

We split this instructions.mdc into the rules it gives an agent

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

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈9

    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:

    Document non-obvious, project- or distribution-specific rules only.

    line 14
  2. Distinctive:

    TEST-01 (MUST): No Always-Run Lint Mandates

    line 80
  3. Distinctive:

    TEST-02 (SHOULD): On-Demand Skill Pointer

    line 81
  4. Distinctive:

    TEST-03 (SHOULD): Domain-Only Operational Notes

    line 82
  5. Distinctive:

    Keep applyTo precise to distributed rule paths.

    line 86
  6. Distinctive:

    Do not embed always-run lint/validate recipes or "hooks handle it" skip explanations in always-on instructions.

    line 87
  7. Distinctive:

    When instruction files are updated, re-evaluate instruction quality against this file's STRUCT/TEST rules.

    line 88
  8. Distinctive:

    Do not include real secrets (tokens, keys, credentials) in instruction files.

    line 97
  9. Distinctive:

    Do not make destructive operations the default in command examples.

    line 98

≈ “Common” is an estimate: at least 1 in 5 of the 6,668 Cursor rule 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
instructions.mdc
---
description: Writing Instruction Files Instructions
globs: **/instructions/*.instructions.md, **/.cursor/rules/*.mdc, **/.kiro/steering/*.md, **/.claude/rules/*.md
---

# Instruction Files Instructions

## Scope

- Scope covers creating and updating instruction and rule files for agent consumption.

## Standards

Document **non-obvious, project- or distribution-specific** rules only. Omit language or ecosystem defaults, generic style guides, and other practices models already know.

### Naming Conventions

| Component               | Rule                                              | Example                                      |
| ----------------------- | ------------------------------------------------- | -------------------------------------------- |
| Package source file     | `<stem>.instructions.md`                          | `go.instructions.md`, `bats.instructions.md` |
| Cursor (distributed)    | `.cursor/rules/<stem>.mdc`                        | `go.mdc`, `bats.mdc`                         |
| Claude (distributed)    | `.claude/rules/<stem>.md`                         | `go.md`, `bats.md`                           |
| Kiro (distributed)      | `.kiro/steering/<stem>.md`                        | `go.md`                                      |
| Title                   | `# <target> Instructions`                         | `# Go Instructions`                          |
| Agent-facing cross-link | Companion wording with stem — not source filename | companion Bats rules (stem `bats`)           |

## Guidelines

### General (G)
- G-01 (MUST): Front Matter
- G-02 (MUST): Title
- G-03 (MUST): applyTo Target Precision
- G-04 (MUST): Portable Cross-References
- G-05 (MUST): Companion applyTo Coverage

### Structure (STRUCT)
- STRUCT-01 (MUST): Five Required Chapters Exist
- STRUCT-02 (MUST): Chapter Order Unified
- STRUCT-03 (MUST): Heading Levels Appropriate
- STRUCT-04 (SHOULD): Standards Chapter Subsections
- STRUCT-05 (MUST): Guidelines Chapter Subsections
- STRUCT-06 (MUST): H3 Heading Format
- STRUCT-07 (MUST): Concise Testing and Validation Chapter
- STRUCT-08 (SHOULD): Critical MUST in Scope

### Guidelines Chapter (GUIDE)
- GUIDE-01 (SHOULD): Code Modification Guidelines
- GUIDE-02 (SHOULD): Tool Usage
- GUIDE-03 (SHOULD): Anti-Patterns
- GUIDE-04 (SHOULD): No ID-less Bullet Rules in Guidelines

### Content Quality (QUAL)
- QUAL-01 (SHOULD): Practical Examples
- QUAL-02 (SHOULD): No Redundancy
- QUAL-03 (SHOULD): Token Efficiency

### Consistency (CONS)
- CONS-01 (SHOULD): Section Names
- CONS-02 (SHOULD): Format
- CONS-03 (SHOULD): Internal Consistency

### Completeness (COMP)
- COMP-01 (SHOULD): Validation Ownership Clear
- COMP-02 (SHOULD): Real Pointers

### Security Guidelines Chapter (SEC)
- SEC-01 (MUST): Tool-Undetectable Risks Documented
- SEC-02 (MUST): Secrets Management
- SEC-03 (MUST): Scope Limited to Document Safety
- SEC-04 (SHOULD): Examples

### Standards Chapter (STD)
- STD-01 (MUST): Standards Chapter Non-Obvious Content
- STD-02 (SHOULD): Tool Standards
- STD-03 (MUST): Consistency
- STD-04 (MUST): Distribution Naming Documented
- STD-05 (MUST): No Guidelines Checklist Duplication in Standards

### Testing and Validation Chapter (TEST)
- TEST-01 (MUST): No Always-Run Lint Mandates
- TEST-02 (SHOULD): On-Demand Skill Pointer
- TEST-03 (SHOULD): Domain-Only Operational Notes

### Code Modification Guidelines

- Keep applyTo precise to distributed rule paths; use stem-based companion cross-links (G-03, G-04, G-05).
- Do not embed always-run lint/validate recipes or "hooks handle it" skip explanations in always-on instructions.
- When instruction files are updated, re-evaluate instruction quality against this file's STRUCT/TEST rules.


## Testing and Validation

On-demand validation: see instructions-review skill SKILL.md.

## Security Guidelines

- Do not include real secrets (tokens, keys, credentials) in instruction files.
- Do not make destructive operations the default in command examples; add explicit warnings when needed.

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.