cursor-rules

Add or edit Cursor rules with standardized placement and YAML frontmatter.

307|59|Updated Jun 2, 2024
One-click install
npx skills add https://github.com/spiriMirror/libuipc --skill cursor-rules-spirimirror
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cursor-rules
Source: https://github.com/spiriMirror/libuipc/tree/main/.cursor/skills/cursor-rules
Command: npx skills add https://github.com/spiriMirror/libuipc --skill cursor-rules-spirimirror

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This guide provides a standardized approach to adding or editing Cursor rules, ensuring consistent placement, naming, and structure across the project.

Core Features & Use Cases

  • Standardized rule placement: place rules under PROJECT_ROOT/.cursor/rules with kebab-case filenames and a .mdc extension
  • Clear rule structure: each rule uses YAML frontmatter (description, globs, alwaysApply) and a Markdown body detailing guidance
  • Collaboration and governance: simplifies onboarding and enforcement of coding and automation guidelines

Quick Start

Create your first rule by adding a new file under .cursor/rules/your-rule-name.mdc with a matching YAML frontmatter and a markdown body.

Frequently Asked Questions about cursor-rules

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

FAQPage Schema
How do I add Cursor rules to my project structure?

To add Cursor rules, create a file under PROJECT_ROOT/.cursor/rules using a kebab-case .mdc extension, then define the rule with YAML frontmatter and a Markdown body. This enforces a predictable rule structure for your project.

What is the required format for a Cursor rules file?

A Cursor rules file requires a .mdc extension with a kebab-case filename. The file must contain YAML frontmatter including a description field, globs, and an optional alwaysApply flag, followed by a Markdown body for guidance.

Why do we need standardized Cursor rules in a software project?

Standardized Cursor rules ensure consistent placement, naming, and structure across a project. This simplifies team onboarding and enforces predictable coding and automation guidelines for maintaining Cursor-based tooling.

Can I use the alwaysApply flag when defining Cursor rules?

Yes, you can use the optional alwaysApply flag within the YAML frontmatter of your .mdc rule file. This flag works alongside the required description and globs fields to control how the Markdown guidance is enforced.

What's the best way to manage Cursor rules for a team?

The best way to manage team Cursor rules is placing them under PROJECT_ROOT/.cursor/rules with kebab-case .mdc filenames. Using standardized YAML frontmatter ensures predictable governance and simplifies collaboration on automation guidelines.