Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Cursor Rules Location
Cursor Rules Location
octohk/laravel-segment
cursor
laravel-segment

description: Rules for placing and organizing Cursor rule files in the repository. globs: .mdc

Install
php artisan boost:add-skill octohk/laravel-segment

Save this content to: .cursor/rules/cursor-rules-location.mdc

---
description: Rules for placing and organizing Cursor rule files in the repository.
globs: *.mdc
---
# Cursor Rules Location

Rules for placing and organizing Cursor rule files in the repository.

<rule>
name: cursor_rules_location
description: Standards for placing Cursor rule files in the correct directory
filters:
  # Match any .mdc files
  - type: file_extension
    pattern: "\\.mdc$"
  # Match files that look like Cursor rules
  - type: content
    pattern: "(?s)<rule>.*?</rule>"
  # Match file creation events
  - type: event
    pattern: "file_create"

actions:
  - type: reject
    conditions:
      - pattern: "^(?!\\.\\/\\.cursor\\/rules\\/.*\\.mdc$)"
        message: "Cursor rule files (.mdc) must be placed in the .cursor/rules directory"

- type: suggest
    message: |
      When creating Cursor rules:

      1. Always place rule files in PROJECT_ROOT/.cursor/rules/:
         ```
         .cursor/rules/
         ├── your-rule-name.mdc
         ├── another-rule.mdc
         └── ...
         ```

      2. Follow the naming convention:
         - Use kebab-case for filenames
         - Always use .mdc extension
         - Make names descriptive of the rule's purpose

      3. Directory structure:
         ```
         PROJECT_ROOT/
         ├── .cursor/
         │   └── rules/
         │       ├── your-rule-name.mdc
         │       └── ...
         └── ...
         ```

4. Never place rule files:
         - In the project root
         - In subdirectories outside .cursor/rules
         - In any other location

examples:
  - input: |
      # Bad: Rule file in wrong location
      rules/my-rule.mdc
      my-rule.mdc
      .rules/my-rule.mdc

      # Good: Rule file in correct location
      .cursor/rules/my-rule.mdc
    output: "Correctly placed Cursor rule file"

metadata:
  priority: high
  version: 1.0
</rule>

description: Rules for placing and organizing Cursor rule files in the repository. globs: *.mdc

Cursor Rules Location

Rules for placing and organizing Cursor rule files in the repository.

actions:

  • type: reject conditions:

    • pattern: "^(?!\.\/\.cursor\/rules\/.*\.mdc$)" message: "Cursor rule files (.mdc) must be placed in the .cursor/rules directory"
  • type: suggest message: | When creating Cursor rules:

    1. Always place rule files in PROJECT_ROOT/.cursor/rules/:
       ```
       .cursor/rules/
       ├── your-rule-name.mdc
       ├── another-rule.mdc
       └── ...
       ```
    
    2. Follow the naming convention:
       - Use kebab-case for filenames
       - Always use .mdc extension
       - Make names descriptive of the rule's purpose
    
    3. Directory structure:
       ```
       PROJECT_ROOT/
       ├── .cursor/
       │   └── rules/
       │       ├── your-rule-name.mdc
       │       └── ...
       └── ...
       ```
    
  1. Never place rule files: - In the project root - In subdirectories outside .cursor/rules - In any other location

examples:

  • input: |

    Bad: Rule file in wrong location

    rules/my-rule.mdc my-rule.mdc .rules/my-rule.mdc

    Good: Rule file in correct location

    .cursor/rules/my-rule.mdc output: "Correctly placed Cursor rule file"

metadata: priority: high version: 1.0

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
jinas/dhivatar
store-doc/laravel-storage-driver
plus-it/laravel-translation-manager
diephp/perhaps
diephp/telegraph
osmaviation/spreadsheet
microsoft/fluentui-system-icons
mmccook/php-json-canonicalization-scheme
middlewares/firewall
qubiqx/montapacking
nyoncode/laravel-package-console
pnscripts/filament-broadquill-lite
pnscripts/laravel-sentfold-lite
vleap/mx-sdk-laravel-internal
twidpay/utils
htetmyathlaing/scout-elasticsearch-driver
artisan-toolbox/front-awesome
ls/client-assistant
users-au/laravel-client
cgv/localized-resource