git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 2/2] Documentation/git-checkout.txt: document 70c9ac2 behavior

From
Junio C Hamano <gitster@pobox.com>
Date
Dec 17, 2012, 07:21 UTC
Message-ID
<7vd2y9nnyb.fsf@alter.siamese.dyndns.org>
In-Reply-To
<1355726702-27974-3-git-send-email-chris@rorvick.com>
Chris Rorvick <chris@rorvick.com> writes:
Show 26 quoted lines
> Document the behavior implemented in 70c9ac2 (DWIM "git checkout
> frotz" to "git checkout -b frotz origin/frotz").
>
> Signed-off-by: Chris Rorvick <chris@rorvick.com>
> ---
>  Documentation/git-checkout.txt | 8 ++++++++
>  1 file changed, 8 insertions(+)
>
> diff --git a/Documentation/git-checkout.txt b/Documentation/git-checkout.txt
> index a47555c..db89cf7 100644
> --- a/Documentation/git-checkout.txt
> +++ b/Documentation/git-checkout.txt
> @@ -25,6 +25,14 @@ branch.
>  
>  	Update the index, working tree, and HEAD to reflect the
>  	specified branch.
> ++
> +If <branch> is not found but there does exist a tracking branch in
> +exactly one remote (call it <remote>) with a matching name, treat as
> +equivalent to
> ++
> +------------
> +$ git checkout -b <branch> --track <remote>/<branch>
> +------------
>  
>  'git checkout' -b|-B <new_branch> [<start point>]::
Thanks; does it format well (I didn't check)?
Previous: Chris RorvickNext: Andrew Ardill
Message 21 of 23 in “Documentation: clarify usage of checkout”
  1. 0/2 Documentation: clarify usage of checkoutChris Rorvick, Dec 17, 2012
  2. 1/2 Documentation/git-checkout.txt: clarify usageChris Rorvick, Dec 17, 2012
  3. Junio C HamanoDec 17, 2012
  4. Johannes SixtDec 17, 2012
  5. Junio C HamanoDec 17, 2012
  6. Johannes SixtDec 17, 2012
  7. Junio C HamanoDec 17, 2012
  8. Andrew ArdillDec 17, 2012
  9. Chris RorvickDec 18, 2012
  10. Philip OakleyDec 17, 2012
  11. Junio C HamanoDec 17, 2012
  12. Andrew ArdillDec 17, 2012
  13. Junio C HamanoDec 17, 2012
  14. Andrew ArdillDec 18, 2012
  15. Junio C HamanoDec 18, 2012
  16. Andrew ArdillDec 18, 2012
  17. Chris RorvickDec 18, 2012
  18. Junio C HamanoDec 18, 2012
  19. Philip OakleyDec 17, 2012
  20. 2/2 Documentation/git-checkout.txt: document 70c9ac2 behaviorChris Rorvick, Dec 17, 2012
  21. Junio C HamanoDec 17, 2012
  22. Andrew ArdillDec 17, 2012
  23. Junio C HamanoDec 17, 2012

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.