@@ -14,6 +14,7 @@ Inspired by [haacked/dotfiles/tree-me](https://github.com/haacked/dotfiles/blob/
1414
1515- Organized worktree structure: ` ~/dev/worktrees/<repo>/<branch> `
1616- Simple commands for common worktree operations
17+ - ** Interactive selection menus** for checkout, remove, pr, and mr commands
1718- GitHub PR support via ` wt pr ` command (uses ` gh ` CLI)
1819- GitLab MR support via ` wt mr ` command (uses ` glab ` CLI)
1920- Shell integration with auto-cd functionality
@@ -73,6 +74,7 @@ This enables:
7374# Checkout existing branch in new worktree
7475wt checkout feature-branch
7576wt co feature-branch # short alias
77+ wt co # interactive: select from available branches
7678
7779# Create new branch in worktree (defaults to main/master as base)
7880wt create my-feature
@@ -81,10 +83,12 @@ wt create my-feature develop # specify base branch
8183# Checkout GitHub PR in worktree (requires gh CLI)
8284wt pr 123 # GitHub PR number
8385wt pr https://github.com/org/repo/pull/123 # GitHub PR URL
86+ wt pr # interactive: select from open PRs
8487
8588# Checkout GitLab MR in worktree (requires glab CLI)
8689wt mr 123 # GitLab MR number
8790wt mr https://gitlab.com/org/repo/-/merge_requests/123 # GitLab MR URL
91+ wt mr # interactive: select from open MRs
8892
8993# List all worktrees
9094wt list
@@ -93,6 +97,7 @@ wt ls # short alias
9397# Remove a worktree
9498wt remove old-branch
9599wt rm old-branch # short alias
100+ wt rm # interactive: select from existing worktrees
96101
97102# Clean up stale worktree administrative files
98103wt prune
@@ -108,6 +113,45 @@ wt --help
108113wt < command> --help
109114```
110115
116+ ### Interactive Selection
117+
118+ When you run ` wt co ` , ` wt rm ` , ` wt pr ` , or ` wt mr ` without arguments, you'll get an interactive selection menu:
119+
120+ ``` bash
121+ # Interactive branch checkout
122+ $ wt co
123+ Use the arrow keys to navigate: ↓ ↑ → ←
124+ ? Select branch to checkout:
125+ ▸ feature/add-auth
126+ feature/update-docs
127+ bugfix/login-issue
128+ main
129+
130+ # Interactive worktree removal
131+ $ wt rm
132+ Use the arrow keys to navigate: ↓ ↑ → ←
133+ ? Select worktree to remove:
134+ ▸ feature/add-auth
135+ feature/update-docs
136+ bugfix/login-issue
137+
138+ # Interactive PR checkout (requires gh CLI)
139+ $ wt pr
140+ Use the arrow keys to navigate: ↓ ↑ → ←
141+ ? Select PR to checkout:
142+ ▸ # 123: Add authentication feature
143+ # 124: Update documentation
144+ # 125: Fix login bug
145+
146+ # Interactive MR checkout (requires glab CLI)
147+ $ wt mr
148+ Use the arrow keys to navigate: ↓ ↑ → ←
149+ ? Select MR to checkout:
150+ ▸ ! 456: Add authentication feature
151+ ! 457: Update documentation
152+ ! 458: Fix login bug
153+ ```
154+
111155### Examples
112156
113157``` bash
0 commit comments