|
| 1 | +# Everything Claude Code for Trae |
| 2 | + |
| 3 | +Bring Everything Claude Code (ECC) workflows to Trae IDE. This repository provides custom commands, agents, skills, and rules that can be installed into any Trae project with a single command. |
| 4 | + |
| 5 | +## Quick Start |
| 6 | + |
| 7 | +### Option 1: Local Installation (Current Project Only) |
| 8 | + |
| 9 | +```bash |
| 10 | +# Install to current project |
| 11 | +cd /path/to/your/project |
| 12 | +TRAE_ENV=cn .trae/install.sh |
| 13 | +``` |
| 14 | + |
| 15 | +This creates `.trae-cn/` in your project directory. |
| 16 | + |
| 17 | +### Option 2: Global Installation (All Projects) |
| 18 | + |
| 19 | +```bash |
| 20 | +# Install globally to ~/.trae-cn/ |
| 21 | +cd /path/to/your/project |
| 22 | +TRAE_ENV=cn .trae/install.sh ~ |
| 23 | + |
| 24 | +# Or from the .trae folder directly |
| 25 | +cd /path/to/your/project/.trae |
| 26 | +TRAE_ENV=cn ./install.sh ~ |
| 27 | +``` |
| 28 | + |
| 29 | +This creates `~/.trae-cn/` which applies to all Trae projects. |
| 30 | + |
| 31 | +### Option 3: Quick Install to Current Directory |
| 32 | + |
| 33 | +```bash |
| 34 | +# If already in project directory with .trae folder |
| 35 | +cd .trae |
| 36 | +./install.sh |
| 37 | +``` |
| 38 | + |
| 39 | +The installer uses non-destructive copy - it will not overwrite your existing files. |
| 40 | + |
| 41 | +## Installation Modes |
| 42 | + |
| 43 | +### Local Installation |
| 44 | + |
| 45 | +Install to the current project's `.trae-cn` directory: |
| 46 | + |
| 47 | +```bash |
| 48 | +cd /path/to/your/project |
| 49 | +TRAE_ENV=cn .trae/install.sh |
| 50 | +``` |
| 51 | + |
| 52 | +This creates `/path/to/your/project/.trae-cn/` with all ECC components. |
| 53 | + |
| 54 | +### Global Installation |
| 55 | + |
| 56 | +Install to your home directory's `.trae-cn` directory (applies to all Trae projects): |
| 57 | + |
| 58 | +```bash |
| 59 | +# From project directory |
| 60 | +TRAE_ENV=cn .trae/install.sh ~ |
| 61 | + |
| 62 | +# Or directly from .trae folder |
| 63 | +cd .trae |
| 64 | +TRAE_ENV=cn ./install.sh ~ |
| 65 | +``` |
| 66 | + |
| 67 | +This creates `~/.trae-cn/` with all ECC components. All Trae projects will use these global installations. |
| 68 | + |
| 69 | +**Note**: Global installation is useful when you want to maintain a single copy of ECC across all your projects. |
| 70 | + |
| 71 | +## Environment Support |
| 72 | + |
| 73 | +- **Default**: Uses `.trae` directory |
| 74 | +- **CN Environment**: Uses `.trae-cn` directory (set via `TRAE_ENV=cn`) |
| 75 | + |
| 76 | +### Force Environment |
| 77 | + |
| 78 | +```bash |
| 79 | +# From project root, force the CN environment |
| 80 | +TRAE_ENV=cn .trae/install.sh |
| 81 | + |
| 82 | +# From inside the .trae folder |
| 83 | +cd .trae |
| 84 | +TRAE_ENV=cn ./install.sh |
| 85 | +``` |
| 86 | + |
| 87 | +**Note**: `TRAE_ENV` is a global environment variable that applies to the entire installation session. |
| 88 | + |
| 89 | +## Uninstall |
| 90 | + |
| 91 | +The uninstaller uses a manifest file (`.ecc-manifest`) to track installed files, ensuring safe removal: |
| 92 | + |
| 93 | +```bash |
| 94 | +# Uninstall from current directory (if already inside .trae or .trae-cn) |
| 95 | +cd .trae-cn |
| 96 | +./uninstall.sh |
| 97 | + |
| 98 | +# Or uninstall from project root |
| 99 | +cd /path/to/your/project |
| 100 | +TRAE_ENV=cn .trae/uninstall.sh |
| 101 | + |
| 102 | +# Uninstall globally from home directory |
| 103 | +TRAE_ENV=cn .trae/uninstall.sh ~ |
| 104 | + |
| 105 | +# Will ask for confirmation before uninstalling |
| 106 | +``` |
| 107 | + |
| 108 | +### Uninstall Behavior |
| 109 | + |
| 110 | +- **Safe removal**: Only removes files tracked in the manifest (installed by ECC) |
| 111 | +- **User files preserved**: Any files you added manually are kept |
| 112 | +- **Non-empty directories**: Directories containing user-added files are skipped |
| 113 | +- **Manifest-based**: Requires `.ecc-manifest` file (created during install) |
| 114 | + |
| 115 | +### Environment Support |
| 116 | + |
| 117 | +Uninstall respects the same `TRAE_ENV` environment variable as install: |
| 118 | + |
| 119 | +```bash |
| 120 | +# Uninstall from .trae-cn (CN environment) |
| 121 | +TRAE_ENV=cn ./uninstall.sh |
| 122 | + |
| 123 | +# Uninstall from .trae (default environment) |
| 124 | +./uninstall.sh |
| 125 | +``` |
| 126 | + |
| 127 | +**Note**: If no manifest file is found (old installation), the uninstaller will ask whether to remove the entire directory. |
| 128 | + |
| 129 | +## What's Included |
| 130 | + |
| 131 | +### Commands |
| 132 | + |
| 133 | +Commands are on-demand workflows invocable via the `/` menu in Trae chat. All commands are reused directly from the project root's `commands/` folder. |
| 134 | + |
| 135 | +### Agents |
| 136 | + |
| 137 | +Agents are specialized AI assistants with specific tool configurations. All agents are reused directly from the project root's `agents/` folder. |
| 138 | + |
| 139 | +### Skills |
| 140 | + |
| 141 | +Skills are on-demand workflows invocable via the `/` menu in chat. All skills are reused directly from the project's `skills/` folder. |
| 142 | + |
| 143 | +### Rules |
| 144 | + |
| 145 | +Rules provide always-on rules and context that shape how the agent works with your code. All rules are reused directly from the project root's `rules/` folder. |
| 146 | + |
| 147 | +## Usage |
| 148 | + |
| 149 | +1. Type `/` in chat to open the commands menu |
| 150 | +2. Select a command or skill |
| 151 | +3. The agent will guide you through the workflow with specific instructions and checklists |
| 152 | + |
| 153 | +## Project Structure |
| 154 | + |
| 155 | +``` |
| 156 | +.trae/ (or .trae-cn/) |
| 157 | +├── commands/ # Command files (reused from project root) |
| 158 | +├── agents/ # Agent files (reused from project root) |
| 159 | +├── skills/ # Skill files (reused from skills/) |
| 160 | +├── rules/ # Rule files (reused from project root) |
| 161 | +├── install.sh # Install script |
| 162 | +├── uninstall.sh # Uninstall script |
| 163 | +└── README.md # This file |
| 164 | +``` |
| 165 | + |
| 166 | +## Customization |
| 167 | + |
| 168 | +All files are yours to modify after installation. The installer never overwrites existing files, so your customizations are safe across re-installs. |
| 169 | + |
| 170 | +**Note**: The `install.sh` and `uninstall.sh` scripts are automatically copied to the target directory during installation, so you can run these commands directly from your project. |
| 171 | + |
| 172 | +## Recommended Workflow |
| 173 | + |
| 174 | +1. **Start with planning**: Use `/plan` command to break down complex features |
| 175 | +2. **Write tests first**: Invoke `/tdd` command before implementing |
| 176 | +3. **Review your code**: Use `/code-review` after writing code |
| 177 | +4. **Check security**: Use `/code-review` again for auth, API endpoints, or sensitive data handling |
| 178 | +5. **Fix build errors**: Use `/build-fix` if there are build errors |
| 179 | + |
| 180 | +## Next Steps |
| 181 | + |
| 182 | +- Open your project in Trae |
| 183 | +- Type `/` to see available commands |
| 184 | +- Enjoy the ECC workflows! |
0 commit comments