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

Re: remote.<name>.merge missing from the git-config man page?

From
Andreas Schwab <schwab@linux-m68k.org>
Date
Mar 8, 2021, 20:57 UTC
Message-ID
<87h7ll2wiz.fsf@igel.home>
In-Reply-To
<YEaM7ruZCvaQQbPI@nand.local>
On Mär 08 2021, Taylor Blau wrote:
Show 24 quoted lines
> On Mon, Mar 08, 2021 at 09:41:14PM +0100, Andreas Schwab wrote:
>> >> >  `git push origin`::
>> >> >  	Without additional configuration, pushes the current branch to
>> >> > -	the configured upstream (`remote.origin.merge` configuration
>> >> > +	the configured upstream (`branch.<name>.merge` configuration
>> >> >  	variable) if it has the same name as the current branch, and
>> >> >  	errors out without pushing otherwise.
>> >>
>> >> That doesn't say what <name> is.  Is that supposed to be <branch>?
>> >> Also, what is "it" referring to in "if it has the same name"?
>> >
>> > <name> refers to the currently-checked-out branch's local name. (That's
>> > how it's used in Documentation/config/branch.txt).
>> >
>> > The antecedent is "the current branch", so I think that this one may
>> > already be quite clear if you read past the parenthesis.
>>
>> That doesn't make sense: "if the current branch has the same name as the
>> current branch".
>
> OK, now I see where your confusion is. I was incorrect in saying the
> antecedent was "the current branch"; it should instead by "the
> configured upstream". IOW, "if both your and the remote copy call the
> branch you have checked out the same thing."

The configured upstream is the value of branch.<name>.merge, isn't it? That would be the name of a remote, not the name of a branch.

Andreas.
-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510  2552 DF73 E780 A9DA AEC1
"And now for something completely different."
Previous: Taylor BlauNext: Taylor Blau
Message 9 of 14 in “remote.<name>.merge missing from the git-config man page?”
  1. Fabien TerraniMar 8, 2021
  2. Eric SunshineMar 8, 2021
  3. Junio C HamanoMar 8, 2021
  4. Taylor BlauMar 8, 2021
  5. Andreas SchwabMar 8, 2021
  6. Taylor BlauMar 8, 2021
  7. Andreas SchwabMar 8, 2021
  8. Taylor BlauMar 8, 2021
  9. Andreas SchwabMar 8, 2021
  10. Taylor BlauMar 8, 2021
  11. Andreas SchwabMar 8, 2021
  12. Junio C HamanoMar 12, 2021
  13. Jonathan NiederMar 13, 2021
  14. Junio C HamanoMar 8, 2021

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.