-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Problem Statement
Users cannot list, switch between, or clean up worktrees using ghwt. Must use workmux directly, which breaks workflow and limits ghwt's value.
Proposed Solution
Add list, switch, remove, and clean commands to ghwt CLI.
Implementation Steps:
- Create
commands/list.pywith list_worktrees() function - Create
commands/remove.pywith remove_worktree() function - Create
commands/switch.pywith switch_worktree() function - Create
commands/clean.pywith clean_worktrees() function - Convert
main.pyto command group using @click.group() - Add status information to list command (active, inactive, missing, age)
- Add
--forceflag to remove command - Add
--older-thanand--mergedflags to clean command - Add
--open-editorflag to switch command - Add
--dry-runflag to clean command - Add tests for each new command
- Update README with command examples
Alternative Approaches
- Use native git worktree list (portability)
- Add interactive TUI for worktree selection
- Integrate with tmux/screen for terminal sessions
Area
- Feature/CLI
Estimated Effort
- Medium (1-2d)
Acceptance Criteria
-
ghwt listshows all worktrees with status -
ghwt switch <branch>changes to worktree directory -
ghwt remove <branch>deletes worktree with confirmation -
ghwt clean --older-than 7dremoves old worktrees - All commands have proper help text
- Add tests for each new command
- Document commands in README with examples
Related Issues
None
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels