create-rule

Create and enforce Cursor rules in .cursor/rules/ with .mdc files.

264|11|Updated Apr 25, 2026
One-click install
npx skills add https://github.com/rkz91/coco --skill create-rule-rkz91
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: create-rule
Source: https://github.com/rkz91/coco/tree/main/adapters/cursor/skills/create-rule
Command: npx skills add https://github.com/rkz91/coco --skill create-rule-rkz91

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This material enables teams to define and enforce Cursor rules that govern AI agent behavior, ensuring consistent guidance across sessions and projects.

Core Features & Use Cases

  • Rule authoring: Create .mdc rule definitions stored under .cursor/rules/ to specify scope, glob patterns, and applicability.
  • Governance: Apply rules to projects to enforce conventions around prompts, file patterns, and rule hierarchies.
  • Maintenance: Version and update rules as guidelines evolve, with a clear lifecycle for rule reviews.

Quick Start

Draft a new rule by adding a .mdc file under .cursor/rules/ with a concise description and applicable glob patterns, then test its behavior in a sample session.

Frequently Asked Questions about create-rule

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create persistent Cursor rules for AI agents?

Create persistent Cursor rules by authoring .mdc files under the .cursor/rules/ directory, defining concise descriptions and applicable glob patterns to provide consistent guidance for AI agents across sessions and projects.

What is the best way to enforce AI governance conventions across projects?

Enforce AI governance conventions by applying rule hierarchies and file patterns within .cursor/rules/ .mdc files, ensuring consistent prompt behavior and project conventions across all AI agent sessions.

How do I structure a .mdc rule file with YAML frontmatter?

Structure a .mdc rule file by adding YAML frontmatter in the file header to define scope, glob patterns, and applicability, saving it under the .cursor/rules/ directory for Cursor to parse.

Does the create-rule approach support versioning for evolving AI guidelines?

Yes, the create-rule approach supports maintenance by allowing you to version and update .mdc rule files as guidelines evolve, providing a clear lifecycle for rule reviews and updates.

When do I need to use glob patterns in Cursor rule files?

Use glob patterns in Cursor rule files when you need to specify the exact file scope and applicability for a rule, ensuring the AI agent only applies the guidance to matching file paths within the project.