Thread (1 message) 1 message, 1 author, 2020-10-07

Re: [PATCH v2 2/2] checkout: learn to respect checkout.guess

From: Junio C Hamano <hidden>
Date: 2020-10-07 16:47:49

Denton Liu [off-list ref] writes:
quoted hunk
diff --git a/Documentation/git-checkout.txt b/Documentation/git-checkout.txt
index afa5c11fd3..28f656d04e 100644
--- a/Documentation/git-checkout.txt
+++ b/Documentation/git-checkout.txt
@@ -193,6 +193,9 @@ branches from there if `<branch>` is ambiguous but exists on the
 linkgit:git-config[1].
 +
 Use `--no-guess` to disable this.
++
+The default behavior can be set via the `checkout.guess` configuration
+variable.
 
 -l::
 	Create the new branch's reflog; see linkgit:git-branch[1] for
diff --git a/Documentation/git-switch.txt b/Documentation/git-switch.txt
index 3759c3a265..5c438cd505 100644
--- a/Documentation/git-switch.txt
+++ b/Documentation/git-switch.txt
@@ -103,6 +103,9 @@ ambiguous but exists on the 'origin' remote. See also
 `checkout.defaultRemote` in linkgit:git-config[1].
 +
 `--guess` is the default behavior. Use `--no-guess` to disable it.
++
+The default behavior can be set via the `checkout.guess` configuration
+variable.
Contrasting the above two, one cannot help but notice that it is
totally unclear how "git checkout" that is not explicitly told by
command line or configuration behaves.  Perhaps "`--guess` is the
default behaviour." needs to be transplated from the description
for "git switch" to clarify?

This is not a new issue, but is made stand out even more prominently
due to the addition.

Thanks.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help