feat: open existing worktree on duplicate pr checkout - #161
Merged
Merged
Conversation
Owner
Review FeedbackHook action should stay
|
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Keep hooks.ActionPR for all pr checkout paths (don't switch to ActionOpen — pr checkout is semantically a PR action) - Rewrite test to verify the actual output message selection logic from pr_cmd.go instead of calling unrelated openExistingWorktree Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
ppn26
force-pushed
the
pr-checkout-already-exists
branch
from
April 1, 2026 07:38
3c5b4c1 to
33adf9b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When
wt pr checkouttargets a branch that already has a worktree, open itinstead of failing with a fatal git error. Fetches latest changes, refreshes
PR cache, and runs hooks with
action="open".Mirrors the behavior already implemented for
wt checkoutin c730458.Breaking Changes
wt pr checkout <number>no longer errors when the branch already has aworktree — it opens it instead.
Test Coverage
🤖 Generated with Claude Code