/tsh-create-custom-rules
Load and follow the tsh-cursor-orchestrator agent skill. Create custom rules for Cursor. There are two types: repository-level rules (cursor-instructions.md) that apply to all Cursor interactions, and file-scoped rules (.mdc files with globs patterns in .cursor/rules/) that target specific files or directories. The user's message following this skill may contain specific requirements or conventions to encode.
Required Skills
Before starting, load and follow these skills:
tsh-creating-rules- for rules file creation workflow, type selection, scope decisions, and validation checklisttsh-technical-context-discovering- for discovering project conventions and workspace patterns before creatingtsh-codebase-analysing- for analyzing workspace for existing coding conventions and patterns
Workflow
- Research workspace conventions: Analyze the workspace for existing coding standards and conventions:
- Project structure and technology stack
- Existing coding patterns and standards
- Any existing rule files (
.cursor/rules/*.mdcorcursor-instructions.md) - Note: this repository currently has NO rule files of either type
- Determine rule type: Help the user choose the appropriate rule type:
- Repo-level (
cursor-instructions.md): applies to all Cursor interactions in the workspace - File-scoped (
.mdcfiles in.cursor/rules/withglobspatterns): applies only when matching files are in context - Guide the decision based on the user's needs and scope
- Repo-level (
- Clarify requirements: Determine what conventions, standards, or behaviors to encode:
- Coding standards and style preferences
- Framework-specific patterns and conventions
- Behavioral guidelines for Cursor in this workspace
- If the user's message already contains requirements, confirm understanding before proceeding
- Create the rules file: Create the rules file with appropriate type, scope, and content. Apply the
tsh-creating-rulesskill workflow for structure and validation. - Review and validate: Review the created rules against best practices:
- Verify scope is appropriate for the rule type
- Confirm guidelines are clear and actionable for Cursor
- Check that file-scoped
globspatterns match intended files (if applicable)
Guidelines
- Repo-level rules (
cursor-instructions.md): Place in.cursor/rules/cursor-instructions.md. Apply to all Cursor interactions — use for project-wide coding standards, naming conventions, architecture decisions. - File-scoped rules (
.mdcfiles withglobs): Place in.cursor/rules/directory. Useglobsglob patterns (relative to workspace root) to target specific files or directories. - This repository currently has NO rule files — the user is starting from scratch. Communicate this context during the research step.
If the user attaches files or provides a description, use them as input for rule design.
When in doubt about the rule type or scope, ask the user for clarification rather than guessing.
Source: kkorus/cursor-collections — distributed by TomeVault.