Mpromp2 — the AI Prompt GeneratorTheme

Skills Library / Cursor & Coding Agents

Cursor Rules & AGENTS.md Setup

Coding agents take their standing instructions from rules files: Cursor's .cursor/rules (and the older .cursorrules), and the cross-tool AGENTS.md convention read by a growing list of agents. This page explains both, how they layer, and gives you a rules file to copy.

How it works

Cursor rules are markdown files in .cursor/rules/, optionally scoped with frontmatter globs so a rule applies only to matching files; a project rules file shapes every completion and chat in that repo. AGENTS.md is the plain-markdown convention - one file at the repo root describing how to build, test, and behave - read by many agents beyond Cursor. Teams typically keep both: AGENTS.md as the canonical, tool-neutral source, and Cursor rules for editor-specific scoping. Write them for a competent new hire: commands, conventions, folder map, and the mistakes to never make.

Setup, step by step

  1. Put AGENTS.md at the repo root: project purpose, build/test commands, layout, conventions, prohibitions
  2. In Cursor, create .cursor/rules/ and split rules by concern (style, testing, a framework) instead of one giant file
  3. Use glob scoping so rules fire only where they apply - a testing rule should not load for CSS
  4. State commands exactly as they are run, including flags; agents copy them verbatim
  5. Review the files when the stack changes; stale rules are worse than none

Copy-ready starter file

✎ Editable — click in, customize or extend this prompt, then copy. Your edits copy with it.
Download AGENTS.md

Field notes

AGENTS.md is the closest thing the industry has to a portable CLAUDE.md - the same facts-as-text, instructions-first craft, in a format every serious coding agent can read. Keep it short enough to be loaded whole, every time.

Keep going

Claude prompts in the prompt library The prompt gateway All skills & guides
AD PLACEMENT — FOOTER BANNER

Mpromp2 — the AI Prompt Generator. Every guide and skill file here is free to use, including commercially.