mirror of
https://github.com/git/git
synced 2024-08-27 11:39:22 +00:00
![Eric Sunshine](/assets/img/avatar_default.png)
The documentation for this option jumps right in with "With `add`", without explaining that `add` is a sub-command of "git worktree". Together with rather odd grammatical structure of the remainder of the sentence, the description can be difficult for newcomers to understand. Clarify by improving the grammar and mentioning "git worktree add" explicitly. Reported-by: Олег Самойлов <splarv@ya.ru> Signed-off-by: Eric Sunshine <sunshine@sunshineco.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
10 lines
502 B
Plaintext
10 lines
502 B
Plaintext
worktree.guessRemote::
|
|
If no branch is specified and neither `-b` nor `-B` nor
|
|
`--detach` is used, then `git worktree add` defaults to
|
|
creating a new branch from HEAD. If `worktree.guessRemote` is
|
|
set to true, `worktree add` tries to find a remote-tracking
|
|
branch whose name uniquely matches the new branch name. If
|
|
such a branch exists, it is checked out and set as "upstream"
|
|
for the new branch. If no such match can be found, it falls
|
|
back to creating a new branch from the current HEAD.
|