# Manage Worktrees

> Manages Git worktrees using gwq. Lists, shows status, removes, and navigates worktrees.

- Skill: `tomevault-io/manage-worktrees` (Agent Skill, multi-file: 2 files)
- Install (CLI): `npx skillmds@latest add tomevault-io/manage-worktrees`
- Raw SKILL.md: https://api.skillmd.com/api/skills/tomevault-io/manage-worktrees/raw
- Safety review: pending (external: skill-scanner PASS, skillspector PASS)
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: tomevault-io (https://skillmd.com/u/tomevault-io)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/tomevault-io/manage-worktrees

---


# /manage-worktrees

Manages Git worktrees using gwq.

## Quick Reference

| Command | Description |
|---------|-------------|
| list | Show all worktrees |
| status | Show git status of all worktrees |
| remove | Remove a worktree |
| path | Show worktree directory path |

**Prerequisite**: gwq must be installed. See `docs/prerequisites.md`.

## Progress Checklist

```
- [ ] Step 1: Parse command
- [ ] Step 2: Execute command
- [ ] Step 3: Report result
```

## Steps

### Command: list

Show all worktrees for the current repository.

```bash
gwq list
```

### Command: status

Show git status of all worktrees.

```bash
gwq status
```

### Command: remove

Remove a worktree.

1. If no worktree specified, show list first:
   ```bash
   gwq list
   ```

2. Confirm with user before removal using AskUserQuestion.

3. Remove the worktree:
   ```bash
   gwq remove <worktree-name>
   ```

Use `--force` flag only if explicitly requested by user.

### Command: path

Show the directory path of a worktree.

```bash
gwq list
```

Parse output to find the worktree path matching the query, then display:
```
Worktree path: <path>

To navigate in your terminal: cd <path>
```

---
> Converted and distributed by [TomeVault](https://tomevault.io/claim/sato-dev1234) — claim your Tome and manage your conversions.
<!-- tomevault:4.0:skill_md:2026-04-13 -->

