This repository contains standardized editor rules for Tekdi projects, organized by technology stack and framework. Rules are available for both Cursor and Antigravity editors.
- Git installed on your system
- Bash shell (available on macOS, Linux, and Windows with WSL/Git Bash)
- Internet connection to clone the repository
-
Download the script:
wget https://raw.githubusercontent.com/tekdi/tekdi-cursor-rules/main/copy-editor-rules.sh
or
curl -O https://raw.githubusercontent.com/tekdi/tekdi-cursor-rules/main/copy-editor-rules.sh
-
Make it executable:
chmod +x copy-editor-rules.sh
-
Run the script:
./copy-editor-rules.sh
The script will:
- Clone this repository to a temporary directory
- Ask you to select your editor (cursor or antigravity)
- Ask you for your project's directory path
- Prompt you to select:
- Project type (backend/frontend)
- Programming language
- Framework (if applicable)
- Copy the appropriate rules to your project's rules directory
- Create backups of any existing rules
- Clean up temporary files automatically
The script will guide you through several prompts:
Editor Selection:
Which editor are you setting up rules for?
1) cursor
2) antigravity
Project Path:
Enter the path of the repository where you want to copy editor rules:
/path/to/your/project
Project Type:
Is this a backend or frontend repository?
1) backend
2) frontend
Language Selection:
- Backend: java, php, python, nodejs
- Frontend: javascript, html, css
Framework Selection (optional):
- Backend Node.js: nestjs
- Backend Python: fastapi, django
- Frontend JavaScript: reactjs, angular
$ ./copy-editor-rules.sh
[INFO] === Editor Rules Copy Script ===
[INFO] This script will clone the tekdi-cursor-rules repository and copy the appropriate rules to your project.
[INFO] Cloning tekdi-cursor-rules repository...
[SUCCESS] Repository cloned successfully to temporary directory
[INFO] Which editor are you setting up rules for?
1) cursor
2) antigravity
1
[INFO] Enter the path of the repository where you want to copy editor rules:
/Users/developer/my-project
[INFO] Is this a backend or frontend repository?
1) backend
2) frontend
1
[INFO] Which programming language are you using?
Supported languages: java, php, python, nodejs
nodejs
[INFO] Which framework are you using? (Press Enter to skip if not using any specific framework)
Available frameworks: nestjs
nestjs
[INFO] Destination directory: /Users/developer/my-project/.cursor/rules
[INFO] Starting file copy process
[SUCCESS] === Copy process completed! ===
[INFO] Rules have been copied to: /Users/developer/my-project/.cursor/rules
[INFO] Total files copied: 12| Editor | Destination |
|---|---|
| cursor | $PROJECT/.cursor/rules |
| antigravity | $PROJECT/.agent/rules |
The script copies rules in the following order:
- Tekdi common rules (from
cursor-rules/1-tekdi/) - Project type rules (from
cursor-rules/2-common/) - Product rules (from
cursor-rules/3-products/) - Language & framework-specific rules:
- cursor: copied from
cursor-rules/4-frontend/orcursor-rules/5-backend/ - antigravity: copied from
antigravity-rules/4-frontend/orantigravity-rules/5-backend/
- cursor: copied from
- Existing rules are automatically backed up to
.editor_rule_backup_[timestamp] - The script validates all paths before making changes
- Temporary files are cleaned up automatically, even if the script is interrupted
Git not found:
[ERROR] Git is not installed. Please install git to use this script.
Install Git from git-scm.com
Network issues:
[ERROR] Failed to clone repository from https://github.com/tekdi/tekdi-cursor-rules.git
Check your internet connection and try again.
Invalid directory:
[ERROR] Directory '/path/to/project' does not exist.
Ensure the directory path exists and is accessible.
tekdi-cursor-rules/
├── cursor-rules/ # Rules for Cursor editor
│ ├── 1-tekdi/ # Common Tekdi rules
│ ├── 2-common/ # Backend/Frontend common rules
│ ├── 3-products/ # Product-specific rules
│ ├── 4-frontend/ # Frontend language/framework rules
│ └── 5-backend/ # Backend language/framework rules
├── antigravity-rules/ # Editor-specific rules for Antigravity
│ ├── 4-frontend/ # Frontend language/framework rules
│ └── 5-backend/ # Backend language/framework rules
└── copy-editor-rules.sh # Automated setup script
Learn more how to use these rules selectively
To add new rules or modify existing ones:
- Fork this repository
- Create a new branch for your changes
- Add your editor rules in the appropriate directory
- Submit a pull request
For issues or questions:
- Create an issue in this repository
- Contact the Tekdi development team