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

Re: git pull behavior changed?

From
Jeff King <peff@peff.net>
Date
Apr 22, 2010, 00:41 UTC
Message-ID
<20100422004136.GA18570@coredump.intra.peff.net>
In-Reply-To
<k2t3abd05a91004211713u24ff93f3of758e5e09c7b8059@mail.gmail.com>
On Wed, Apr 21, 2010 at 08:13:48PM -0400, Aghiles wrote:
> I don't have the information handy but it was most probably pre-1.5.
> I don't know if my 'branching habits' are common, but I found that
> the old behavior to be more natural with the way we work (creating
> branches for quick parallel work).

OK, then the behavior did change for you. But you are probably about 3 years too late to complain and try to get it changed. :)

> If the current behavior is here to stay, I would humbly suggest to
> mention the 'git checkout -b x origin' syntax in the manual (and
> 'git branch --track x origin').

It is in the checkout manual, but I think the subtlety that you missed is that "--track" is going to care about whether you start your branch from your local "master" or the remote "master". Even if they're at the same commit, you are interested conceptually in basing your work on what the remote is doing. Maybe we could talk about this in the definition of <start-point>, I guess.

You may also be interested to know that "git checkout foo" these days when you have no "foo" branch will do the equivalent of "git checkout -b --track foo origin/foo", which would also do what you want.

-Peff
Previous: AghilesNext: Aghiles
Message 12 of 22 in “git pull behavior changed?”
  1. AghilesApr 21, 2010
  2. Sverre RabbelierApr 21, 2010
  3. AghilesApr 21, 2010
  4. AghilesApr 21, 2010
  5. Sverre RabbelierApr 21, 2010
  6. Matthieu MoyApr 21, 2010
  7. AghilesApr 21, 2010
  8. Matthieu MoyApr 21, 2010
  9. AghilesApr 21, 2010
  10. Jeff KingApr 22, 2010
  11. AghilesApr 22, 2010
  12. Jeff KingApr 22, 2010
  13. AghilesApr 22, 2010
  14. Jeff KingApr 22, 2010
  15. Randal L. SchwartzApr 21, 2010
  16. AghilesApr 21, 2010
  17. Petr BaudisApr 22, 2010
  18. Junio C HamanoApr 22, 2010
  19. Creating tracked branchesPetr Baudis, Apr 22, 2010
  20. Andreas SchwabApr 22, 2010
  21. Petr BaudisApr 22, 2010
  22. AghilesApr 22, 2010

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.