Coding & DevelopmentāŒØļøcursor🌐universal

Cursor AI Project Rules for Modern Development

A set of cursor rules for Cursor AI IDE that support PHP, Python, JavaScript and Drupal-specific rules

Quick Start

Install this Skill

npx skills add ivangrynenko/cursorrules
# Cursor AI Project Rules for Modern Development

[![Cursor Rules Tests](https://github.com/ivangrynenko/cursor-rules/actions/workflows/test.yml/badge.svg)](https://github.com/ivangrynenko/cursor-rules/actions/workflows/test.yml)

## šŸ“Œ About This Repository
This repository contains a **comprehensive set of Cursor AI rules** designed to **enhance efficiency, enforce coding standards, and automate best practices** across **multiple programming languages and frameworks**, including **PHP/Drupal, JavaScript/React/Vue, Python, and DevOps technologies**, with a **strong focus on security** following **OWASP Top 10** guidelines.

These rules help **Cursor AI** assist developers by:
- Enforcing coding standards and best practices
- Ensuring tests and documentation remain up to date
- Detecting inefficiencies in AI query usage and improving response quality
- Providing automated suggestions for commit messages, dependencies, and performance optimisations

---

## šŸš€ Who Is This For?
This repository is ideal for:
- **PHP & Drupal developers** following Drupal coding standards and security best practices
- **Frontend developers** working with JavaScript, React, Vue, Tailwind, and other modern frameworks
- **Python developers** building secure applications following OWASP guidelines
- **DevOps engineers** working with Docker, CI/CD, and deployment workflows
- **Security-conscious developers** implementing OWASP Top 10 protections
- **Software teams** looking for a structured, automated workflow with comprehensive rule sets
- **Open-source contributors** who want standardized development and security practices

---

## šŸ“„ Installation

### Interactive Installation (Recommended)

For a fully interactive installation with prompts:

```bash
# Step 1: Download the installer
curl -s https://raw.githubusercontent.com/ivangrynenko/cursor-rules/main/install.php -o install.php

# Step 2: Run the installer interactively
php install.php
```

This two-step process ensures you get the interactive experience with:
- Prompts to choose which rule sets to install (Core, Web Stack, Python, or All)
- Option to remove the installer file after installation (defaults to yes)

### Quick Non-Interactive Installation

For a quick installation without prompts (installs core rules only):

```bash
curl -s https://raw.githubusercontent.com/ivangrynenko/cursor-rules/main/install.php | php
```

or install rules by tag expression
```bash
curl -s https://raw.githubusercontent.com/ivangrynenko/cursor-rules/main/install.php | php -- --tags "language:javascript category:security"
```

āš ļø **Note**: When using the curl piping method above, interactive mode is **not possible** because STDIN is already being used for the script input. The installer will automatically default to installing core rules only.

### Installation with Specific Options

To install with specific options and bypass the interactive mode:

```bash
curl -s https://raw.githubusercontent.com/ivangrynenko/cursor-rules/main/install.php | php -- [options]
```

For example, to install all rules:

```bash
curl -s https://raw.githubusercontent.com/ivangrynenko/cursor-rules/main/install.php | php -- --all
```

### Installation Options

The installer supports the following options:
- `--core`: Install core rules only
- `--web-stack` or `--ws`: Install web stack rules (includes core rules)
- `--python`: Install Python rules (includes core rules)
- `--all`: Install all rules
- `--yes` or `-y`: Automatically answer yes to all prompts
- `--destination=DIR`: Install to a custom directory (default: .cursor/rules)
- `--debug`: Enable detailed debug output for troubleshooting installation issues
- `--ignore-files <opt>`: Control installation of .cursorignore files (yes, no, ask), default's to yes
- `--help` or `-h`: Show help message

### .cursorignore Files

The installer can automatically add recommended `.cursorignore` and `.cursorindexingignore` files to your project. These files tell Cursor AI which files and directories to exclude from processing, which helps to:

- **Improve performance** by skipping large generated files, vendor directories, and node_modules
- **Reduce noise** in AI responses by focusing only on relevant project files
- **Prevent unnecessary context** from third-party code being included in AI prompts

The `.cursorignore` file ensures files are not indexed by Cursior and they are not read by Cursor or sent to the models for processing. This is a good setting for files that may contain secrets or other information you'd prefer to keep private. The `.cursorindexingignore` file is just for indexing and is there mainly for performance reasons.

By default, the installer will add these files (controlled by the `--ignore-files` option). You can:
- Set to `yes` (default): Always install ignore files
- Set to `no`: Never install ignore files
- Set to `ask`: Prompt during installation

If you need to modify the ignore patterns, you can edit the `.cursorignore` files manually after installa

... (truncated)