create_worktree
Automatically create a git worktree for a given ticket and branch, with dependency installation and .env file copying. Organizes worktrees in a separate directory.
Instructions
Create a new git worktree with automatic setup. Auto-detects username from GitHub/git, installs dependencies, and copies .env files. Worktrees are created at ../-worktrees/username/TICKET/branch-name
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"ticket": "<ticket>",
"branchName": "<branchName>"
},
"name": "create_worktree"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cwd | No | Optional: Working directory (defaults to current directory) | |
| ticket | Yes | Ticket number (e.g., CO-4493, PROJ-123) | |
| openIde | No | Optional: Open worktree in IDE after creation | |
| branchName | Yes | Branch name (spaces will be converted to hyphens, e.g., "billing feature" -> "billing-feature") |