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

Re: [PATCH] Only warn about missing branch.<n>.merge in pull.

From
JWJosef Weidendorfer <josef.weidendorfer@gmx.de>
Date
Dec 19, 2006, 00:59 UTC
Message-ID
<200612190159.58658.Josef.Weidendorfer@gmx.de>
In-Reply-To
<Pine.LNX.4.63.0612182135360.19693@wbgn013.biozentrum.uni-wuerzburg.de>
On Monday 18 December 2006 21:43, Johannes Schindelin wrote:
Show 15 quoted lines
> Hi,
> 
> On Mon, 18 Dec 2006, Junio C Hamano wrote:
> 
> > 	$ git pull second
> > ...
> >  (3) branch.$current.merge was a mistake.  It should have been
> >      branch.$current.merge.$remote.  In other words, the
> >      configuration should have been about the current branch and
> >      the remote repository pair.
> > 
> >  (4) the current configuration mechanism is fine, but the code
> >      is not.  We should forbid "the first branch listed" rule
> >      from being applied for "git pull second", and require the
> >      users to explicitly say which branch(es) to merge.
Show 6 quoted lines
> I fetch/merge criss-crossed over my machines, so this affects me. Until 
> the recent changes, I _always_ fetched/merged with explicit remote and 
> branch. This keeps me unconfused about what I actually do.
> 
> With the options you list, I'd say (3) with (4) as a fallback is the way 
> to go.

I agree. Despite of this, I just sent out the quick fix.

Show 7 quoted lines
> However, I would actually reuse our versatile (often hated?) config  
> handling:
> 
> [branch "xyz"]
> 	remote = blabla # this is the default remote
> 	merge = master # this is the default branch for the default remote
> 	merge = pu for remote second # merge 'pu' if pulling from second

Looks a little bit confusing, but is fine with me. I even would remove the need for the word "remote" in the second merge line. Anybody using this has to look it up in the documentation, anyway. Because these options are not really self-describing.

Josef
Previous: Santi BéjarNext: Junio C Hamano
Message 3 of 8 in “Only warn about missing branch.<n>.merge in pull.”
  1. Only warn about missing branch.<n>.merge in pull.Shawn O. Pearce, Dec 18, 2006
  2. Santi BéjarDec 18, 2006
  3. Josef WeidendorferDec 19, 2006
  4. Junio C HamanoDec 19, 2006
  5. Johannes SchindelinDec 19, 2006
  6. Junio C HamanoDec 19, 2006
  7. Johannes SchindelinDec 19, 2006
  8. Shawn PearceDec 19, 2006

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.