@lanquarden/pi-dev-worktrees
v0.5.3
Published
Pi extension for isolated branch workspaces — git worktrees via wtp and optional devcontainer targeting
Downloads
1,235
Maintainers
Readme
@lanquarden/pi-dev-worktrees
A pi extension that provides isolated branch workspaces using git worktrees (via wtp) and optional devcontainer targeting.
Features
- Worktree isolation — create/switch/remove git worktrees per branch; all bash commands run inside the active worktree
- Devcontainer targeting — start, stop, rebuild, and route bash commands into the project's devcontainer
- File tool routing — read/write/edit with relative paths automatically route to the active worktree
- Composable — worktree + devcontainer combine: commands run in the container at the worktree path
- HOST: escape hatch — prefix any command with
HOST:to bypass all routing - Git/gh passthrough — git, gh, and find commands always run on the host
Install
pi install npm:@lanquarden/pi-dev-worktreesRequirements
gitwtpv2+ (for worktree features)devcontainerCLI (for container features)
Commands
| Command | Description |
|---------|-------------|
| /worktree [set] <branch> | Create or switch to a wtp-managed worktree |
| /worktree off | Deactivate worktree routing |
| /worktree status | Snapshot of all worktrees and container status |
| /worktree remove <branch> | Remove a worktree |
| /worktree prune | Clear stale worktree metadata |
| /worktree init | Interactively create .wtp.yml |
| /worktree hooks ... | Manage post-create hooks |
| /devcontainer on | Start or reuse the devcontainer |
| /devcontainer off | Disable container targeting (leaves container running) |
| /devcontainer stop | Stop the container entirely |
| /devcontainer rebuild | Rebuild the container image (--build-no-cache) |
| /devcontainer logs | Tail the startup log |
See the repo README for full documentation.
Dashboard Plugin
For pi-agent-dashboard integration, install @lanquarden/pi-dev-worktrees-dashboard-plugin.
