projectb-create-rule

Create persistent project rules as .mdc files with YAML frontmatter for AI agents.

Updated May 28, 2023
One-click install
npx skills add https://github.com/steveulrich/ProjectB --skill projectb-create-rule-steveulrich
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: projectb-create-rule
Source: https://github.com/steveulrich/ProjectB/tree/main/.agents/skills/projectb-create-rule
Command: npx skills add https://github.com/steveulrich/ProjectB --skill projectb-create-rule-steveulrich

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Teams need a consistent way to give AI coding agents persistent project context, but ad-hoc instructions get lost between sessions. This Skill standardizes the creation and editing of project rule files so agent behavior stays consistent across conversations. ## Core Features & Use Cases - Rule Authoring: Creates .mdc rule files in .cursor/rules/ with YAML frontmatter containing description, globs, and alwaysApply fields. - Scope Inference: Infers the narrowest useful scope from conversation context and asks targeted questions only when file patterns or applicability remain ambiguous. - Configuration Modes: Supports always-on rules for universal standards and glob-scoped rules that activate only for matching file types. - Use Case: After discussing error-handling conventions in a TypeScript project, ask the agent to codify them; it produces a typescript-standards.mdc rule with concrete good/bad code examples applied to **/*.ts files. ## Quick Start Ask the agent to create a project rule that enforces your TypeScript error-handling standards for all files matching **/*.ts.

Frequently Asked Questions about projectb-create-rule

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

FAQPage Schema
How do I create persistent rules for an AI coding agent?▼

Create a .mdc file in the .cursor/rules/ directory with YAML frontmatter containing a description, optional globs file pattern, and an alwaysApply flag. The Markdown body below the frontmatter holds the actual rule content the agent follows.

What is the difference between alwaysApply and globs in rule files?▼

alwaysApply: true makes a rule active in every session regardless of context, while globs restricts a rule to activate only when matching files are open. Use alwaysApply for universal standards and globs like **/*.ts for file-specific conventions.

How do I scope a rule to specific file types?▼

Set the globs field in the rule's frontmatter to a file pattern such as **/*.ts or backend/**/*.py. The rule then applies only when files matching that pattern are being worked on, keeping unrelated sessions unaffected.

Does this rule format work outside of Cursor-compatible hosts?▼

The .cursor/rules/ paths and .mdc schema apply only to verified compatible hosts. For other products such as current Codex, resolve the active host first and use its installed creation skill or current documentation instead.

Why should project rules be kept short and split into multiple files?▼

Rules should stay under 50 lines with one concern per file so the agent can load and apply them reliably. Large multi-topic rules dilute focus, so split distinct topics like TypeScript standards and React patterns into separate .mdc files.