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

Re: [PATCH] Fix renaming branch without config file

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Apr 5, 2007, 17:51 UTC
Message-ID
<Pine.LNX.4.63.0704051951170.4045@wbgn013.biozentrum.uni-wuerzburg.de>
In-Reply-To
<B0C79D8E-07A8-4178-B0A6-698EB2BB5A2A@gnat.com>
Hi,
On Thu, 5 Apr 2007, Geert Bosch wrote:
Show 14 quoted lines
> 
> On Apr 5, 2007, at 11:30, Johannes Schindelin wrote:
> > I don't think this is correct. git_config_rename_section() _should_ return
> > an error.
> > 
> > > Otherwise, renaming a branch would abort, leaving the repository in an
> > > inconsistent state.
> > 
> > This should take the hint from --rename-section, and print a warning (or
> > not).
> 
> Looking at the code, I deduced that git_config_rename_section()
> returns a positive count of sections renamed, 0 if no matching
> section exists and negative for another error condition.
Ah, yes. You are completely right!
> The proposed patch makes the behavior of an absent config file the same 
> as the behavior of an empty one, which seems sane to me. There should be 
> no warning, as it is perfectly fine to have no config file. Could you 
> elaborate on why you believe my patch is not correct?
I elaborate by taking my objections back. Fair enough?

Ciao, Dscho

Previous: Geert BoschNext: Geert Bosch
Message 4 of 5 in “Fix renaming branch without config file”
  1. Fix renaming branch without config fileGeert Bosch, Apr 5, 2007
  2. Johannes SchindelinApr 5, 2007
  3. Geert BoschApr 5, 2007
  4. Johannes SchindelinApr 5, 2007
  5. Geert BoschApr 6, 2007

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.