create-rules

Creates AI rule files with required YAML frontmatter in the rules directory.

2|Updated Jun 8, 2026
One-click install
npx skills add https://github.com/HACK-WU/skills --skill create-rules-hack-wu
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: create-rules
Source: https://github.com/HACK-WU/skills/tree/main/skills/create-rules
Command: npx skills add https://github.com/HACK-WU/skills --skill create-rules-hack-wu

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Teams using AI coding assistants need consistent, well-formed rule files, but manually writing frontmatter fields like description, alwaysApply, enabled, and updatedAt is error-prone and often produces invalid or incomplete rules. ## Core Features & Use Cases - Guided Rule Creation: Walks the user through collecting rule name, description, alwaysApply, enabled, and rule content before generating the file. - Schema Enforcement: Generates rules/*.md files with the mandatory frontmatter fields (description, alwaysApply, enabled, updatedAt, provider) in the correct format. - Best-Practice Templates: Provides a structured rule body layout (Rules, Execution, Exceptions) and writing guidelines such as kebab-case naming and the 100-line limit. - Use Case: A user says "create a rule that runs auto-review after every document change" and receives a ready-to-copy rules/auto-review.md file with valid frontmatter and structured content. ## Quick Start Ask the assistant to create a new rule file describing its purpose, whether it always applies, and its instructions, then copy the generated file into your project's rules directory.

Frequently Asked Questions about create-rules

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

FAQPage Schema
How do I create an AI rule file for my project?

Provide the rule name in kebab-case, a one-sentence description, whether it always applies, and the rule content. The skill generates a rules/*.md file with the required frontmatter, which you copy into your project's rules directory.

What frontmatter fields are required in a rule file?

Every rule file must include description, alwaysApply, enabled, and updatedAt in ISO 8601 format. The provider field is optional and can be left empty.

What is the difference between alwaysApply true and false?

alwaysApply true makes the rule a global rule applied in every conversation, such as coding standards. False makes it a conditional rule that only activates in matching scenarios.

Does the skill installer distribute rule files automatically?

No, skill-install.sh only manages skill installation and synchronization. Rule files must be copied manually into the target project's rules directory or tracked in version control.

How long should a rule file be?

Rule files should stay under 100 lines with structured sections for rules, execution, and exceptions. Use tables and lists instead of lengthy explanations to keep instructions direct.