Commit 964b27f
authored
feat(workspace): accept repo@branch handle in worktree remove (#746)
`workspace worktree remove` only accepted the two-arg `<repo> <branch>`
form and rejected the `<repo>@<branch-slug>` handle that the rest of the
workspace surface (list/show/path/finalize/cleanup output) prints and
accepts. Copying a handle from `list`/cleanup output and pasting it into
`remove` failed every time.
Accept a single `<repo>@<branch-slug>` handle as the first positional in
addition to the existing two-arg form. When both positionals are present
the two-arg form wins as the disambiguator; a lone first arg containing
`@` is split on the first `@`. The underlying ability already slugifies
the branch, so passing the slug half is safe and idempotent.
Closes #7451 parent d644e17 commit 964b27f
1 file changed
Lines changed: 17 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3459 | 3459 | | |
3460 | 3460 | | |
3461 | 3461 | | |
3462 | | - | |
| 3462 | + | |
3463 | 3463 | | |
| 3464 | + | |
3464 | 3465 | | |
3465 | 3466 | | |
3466 | 3467 | | |
| 3468 | + | |
3467 | 3469 | | |
3468 | 3470 | | |
3469 | 3471 | | |
| |||
3746 | 3748 | | |
3747 | 3749 | | |
3748 | 3750 | | |
3749 | | - | |
3750 | | - | |
| 3751 | + | |
| 3752 | + | |
| 3753 | + | |
| 3754 | + | |
| 3755 | + | |
| 3756 | + | |
| 3757 | + | |
| 3758 | + | |
| 3759 | + | |
| 3760 | + | |
| 3761 | + | |
| 3762 | + | |
3751 | 3763 | | |
3752 | 3764 | | |
3753 | | - | |
3754 | | - | |
| 3765 | + | |
| 3766 | + | |
3755 | 3767 | | |
3756 | 3768 | | |
3757 | 3769 | | |
| |||
0 commit comments