Cursor Rules
Auto-detect your stack and generate a tailored .cursorrules file. npx cursor-init
Install / Use
/learn @Kabi10/Cursor RulesREADME
cursor-compose
Auto-detect your project's stack and generate Cursor project rules in one command. No cloning required.
npx cursor-compose
Writes .cursor/rules/project.mdc — the current Cursor format. Legacy .cursorrules also supported.
What it does
- Scans your project for
package.json,requirements.txt,pubspec.yaml, etc. - Shows which modules were detected, lets you toggle extras
- Writes a composed
.cursor/rules/project.mdcto your project root
Detected stacks
| File found | Modules added |
|-----------|--------------|
| next in package.json | nextjs + typescript |
| typescript in package.json | typescript |
| @supabase/supabase-js | supabase |
| drizzle-orm | drizzle |
| shadcn / @radix-ui | shadcn |
| fastapi in requirements.txt | fastapi |
| flutter: in pubspec.yaml | flutter |
core is always included.
Optional modules
Select these manually during init:
saas— multi-tenancy, billing, feature flagsecommerce— cart, checkout, inventory, paymentsclaude-code— CLAUDE.md conventions, memory systemagentic— agent loop patterns, tool use safety
Requirements
Node.js 18+
Modular builder (advanced)
If you prefer to compose rules with a script instead of npx, the original
build-rules.ps1 (Windows) and build-rules.sh (Unix) are still available after cloning.
Contributing
See CONTRIBUTING.md. Adding a new module is just adding a .md file to modules/.
License
MIT
