A comprehensive collection of coding standards, workflow guidelines, and best practices for modern web development with Cursor IDE. This repository provides AI-powered rules that enforce consistent patterns across your projects.
This repository contains structured rules (.mdc files) that guide Cursor's AI assistant to follow your team's coding standards automatically. These rules cover everything from package management to deployment strategies, ensuring consistency and quality across your codebase.
- KillzoneGaming/kzg-discord-banner-changer
- KillzoneGaming/kzg-discord-tracker-bot
- KillzoneGaming/kzg-discord-oidc-worker
- KillzoneGaming/kzg-rules-website-next
- KillzoneGaming/kzg-servers-connect
- KillzoneGaming/kzg-staff-profile-picture-grabber
- KillzoneGaming/kzg-surf-maps-discord-bot
- KillzoneGaming/kzg-vip-confirmation-email-worker
- KillzoneGaming/kzg-website-nextjs
- KillzoneGaming/kzg-workshop-map-puller
- KillzoneGaming/Twitter-URL-Fixer-Discord-Bot
- Master Coding Guidelines (
general.mdc) - React 19, Next.js, Ultracite (Biome), Bun, TSDoc, and agent-optimized patterns - Bun & Biome Workflow (
bun.mdc) - Strict Bun package management, native testing, and Biome linting - Next.js & React (
react-nextjs.mdc) - App Router patterns, Server Components, Shadcn UI, and state management - Git Standards (
git.mdc) - Conventional Commits and atomic change practices - Cloudflare (
cloudflare.mdc) - Workers deployment, Edge runtime constraints, and R2 storage - Drizzle ORM (
drizzle.mdc) - Schema definitions, migrations, and D1 best practices
- Rule Architect (
rule-architect.mdc) - Automatic detection and suggestion of new project-specific rules - Global Rule Manager (
global-rule-manager.mdc) - Centralized rule management and synchronization from GitHub - Planning Agent (
plan.mdc) - Structured planning workflows with sequential thinking and research tools - PRD & Task Management (
prd-file-structure-and-taskmanagement.mdc) - Project requirements, design docs, and master task list management
- Clone this repository into your project's
.cursor/rulesdirectory:
mkdir -p .cursor
git clone https://github.com/mynameistito/cursor-rules.git .cursor/rules- Add to
.gitignore(to prevent nested repo issues):
# Cursor Rules (Managed via Global Sync)
.cursor/rules/- Resync Context in Cursor IDE to load the rules.
For automated setup, use the bootstrap workflow defined in the rules:
# This will create local context directories and sync rules
# Follow the prompts in your terminal./
βββ .cursor/
βΒ Β βββ commands/
βΒ Β βΒ Β βββ build.md
βΒ Β βΒ Β βββ commit.md
βΒ Β βΒ Β βββ issues.md
βΒ Β βΒ Β βββ planning-agent.md
βΒ Β βΒ Β βββ security-review.md
βΒ Β βββ rules/
βΒ Β βΒ Β βββ bun.mdc
βΒ Β βΒ Β βββ cloudflare.mdc
βΒ Β βΒ Β βββ drizzle.mdc
βΒ Β βΒ Β βββ general.mdc
βΒ Β βΒ Β βββ git.mdc
βΒ Β βΒ Β βββ global-rule-manager.mdc
βΒ Β βΒ Β βββ heroui.mdc
βΒ Β βΒ Β βββ naming-convention.md
βΒ Β βΒ Β βββ plan.mdc
βΒ Β βΒ Β βββ prd-file-structure-and-taskmanagement.mdc
βΒ Β βΒ Β βββ react-nextjs.mdc
βΒ Β βΒ Β βββ rule-architect.mdc
βΒ Β βββ worktrees.json
βββ scripts/
βΒ Β βββ auto-push-cursor-rules.ps1
βΒ Β βββ update-repos.sh
βΒ Β βββ update-structure.sh*
βββ .gitattributes
βββ .gitignore
βββ LICENSE
βββ README.md
Rules are written in Markdown with frontmatter metadata:
---
description: Brief description of what this rule enforces
globs: **/*.ts, **/*.tsx # Files this rule applies to
alwaysApply: true # Whether to apply globally
---
# Rule Title
**Trigger:** When this rule should activate
## 1. Standard
* **Requirement:** Description
* **Example:** Code example- β Bun as the exclusive package manager
- β
bun.lockbas single source of truth - β
bunxfor CLI tools (nevernpx)
- β Biome for linting and formatting
- β
No
anytypes (useunknown+ Zod) - β Named exports only (no default exports)
- β TSDoc documentation standards
- β Server Components by default
- β Shadcn UI components
- β TanStack Query for client data fetching
- β Server Actions for mutations
- β Conventional Commits format
- β Atomic changes
- β Pre-commit linting checks
The Rule Architect will automatically detect patterns and suggest new rules. You can also manually create rules:
- Create a new
.mdcfile in.cursor/rules/ - Follow the rule template format
- Specify appropriate
globsfor file targeting - Set
alwaysApply: falsefor contextual rules
---
description: Payment processing standards for Stripe integration
globs: src/payment/**/*.ts
alwaysApply: false
---
# Payment Standards
**Trigger:** When working with payment-related code
## 1. Error Handling
* **Requirement:** All Stripe calls must be wrapped in try/catch
* **Logging:** Use structured logging to Datadog| Rule | Scope | Always Applied |
|---|---|---|
general.mdc |
Master coding standards, React 19, TypeScript | β Yes |
bun.mdc |
Package management, scripts, testing | β Yes |
react-nextjs.mdc |
React/Next.js components, App Router | β Yes |
git.mdc |
Commit messages, version control | β No |
cloudflare.mdc |
Cloudflare Workers, Edge runtime | β No |
drizzle.mdc |
Database schemas, migrations, D1 | β No |
rule-architect.mdc |
Rule detection and suggestion | β Yes |
global-rule-manager.mdc |
Rule synchronization and bootstrap | β Yes |
plan.mdc |
Planning workflows and task management | β No |
prd-file-structure-and-taskmanagement.mdc |
PRD, design docs, task lists | β No |
- Fork this repository
- Create a feature branch
- Add/Update rules following the established format
- Test rules in a sample project
- Submit a pull request with clear description
- Use descriptive, kebab-case filenames
- Include comprehensive examples
- Specify precise
globspatterns - Document the "why" not just the "what"
- Add TSDoc examples for complex patterns
MIT License - see LICENSE file for details.
- Resync Context after updating rules to ensure Cursor picks up changes
- Use specific globs to avoid rule conflicts
- Test rules in a small project before applying globally
- Keep rules focused - one rule file per concern area
Maintained by: My Name is Tito