Re: [PATCH v10 0/4] worktree add: improve message for ambiguous remote branch name
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Aug 27, 2026, 17:32 UTC
- Message-ID
- <xmqq4igfa2pv.fsf@gitster.g>
- In-Reply-To
- <pull.2197.v10.git.1787841717.gitgitgadget@gmail.com>
"Yoichi NAKAYAMA via GitGitGadget" <gitgitgadget@gmail.com> writes:
Show 17 quoted lines
> 'git worktree add ../foo-dir bar-topic' fails to dwim when there are > multiple remote branches with name `bar-topic'. But it doesn't display > meaningful message as 'git checkout bar-topic' does under the same > situation. > > We improve this by adding advice and modify the error message for worktree > add. > > By Junio's suggestion, we include matched remote names in the advice. It is > applied to checkout, too. > > We also fix the behavior of --guess-remote when there are multiple matches. > > Changes from the previous patch: > > * [1/4] fix the function name and add detailed commit message > * [2/4] change type of tracking_name_data.remote_names
This iteration looks good to me. Let's mark it for 'next' unless we hear other comments in a few days.
Thanks.