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

Re: Beginner question on "Pull is mostly evil"

From
David Kastrup <dak@gnu.org>
Date
May 7, 2014, 16:20 UTC
Message-ID
<87iophr26m.fsf@fencepost.gnu.org>
In-Reply-To
<0C723FEB5B4E5642B25B451BA57E2730751C2642@S1P5DAG3C.EXCHPROD.USA.NET>
Jim Garrison <jim.garrison@nwea.org> writes:
Show 10 quoted lines
> During my initial self-education I came across the maxim "don't pull,
> fetch+merge instead" and have been doing that.  I think I followed
> most of the "pull is (mostly) evil" discussion but one facet still
> puzzles me: the idea that pull will do a merge "in the wrong
> direction" sometimes.
>
> Do I understand correctly that this occurs only in the presence of
> multiple remotes?
> Can someone provide a simple example of a situation where pull would
> do the "wrong" thing?

That's basically unavoidable. Two opposing directions are actually part of the same workflow usually handled by "git pull":

"Codeveloper X sends a pull request to Y who maintains the mainline. Y executes git pull to merge X' sidebranch into the mainline."

"Codeveloper X executes git pull in order to merge the mainline from Y back into his private sidebranch."

-- 
David Kastrup
Previous: Jim GarrisonNext: Jeff King
Message 2 of 11 in “Beginner question on "Pull is mostly evil"”
  1. Jim GarrisonMay 7, 2014
  2. David KastrupMay 7, 2014
  3. Jeff KingMay 7, 2014
  4. Junio C HamanoMay 7, 2014
  5. Jim GarrisonMay 7, 2014
  6. Junio C HamanoMay 7, 2014
  7. Stephen & Linda SmithMay 8, 2014
  8. How to keep a project's canonical history correct.Stephen P. Smith, May 9, 2014
  9. Stephen SmithMay 9, 2014
  10. Junio C HamanoMay 9, 2014
  11. Stephen & Linda SmithMay 10, 2014

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.