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

Re: [PATCH] doc: add note about ignoring --no-create-reflog

From
Jeff King <peff@peff.net>
Date
Feb 1, 2017, 22:35 UTC
Message-ID
<20170201223520.b4er3av67ev5m3ls@sigill.intra.peff.net>
In-Reply-To
<xmqq4m0do86p.fsf@gitster.mtv.corp.google.com>
On Wed, Feb 01, 2017 at 02:30:38PM -0800, Junio C Hamano wrote:
Show 16 quoted lines
> > Notes:
> >     In a previous discussion (<xmqqbmunrwbf.fsf@gitster.mtv.corp.google.com>) it
> >     was found that git-branch and git-tag accept a "--no-create-reflog" argument,
> >     but it has no effect, does not produce a warning, and is undocumented.
> 
> Reading what Peff said in the thread, I do not think we actively
> wanted this behaviour; we agreed that it is merely acceptable.
> 
> So perhaps s/this behaviour is intentional/this is known/ to weaken
> the log message?  That way, when somebody else who really cares
> comes later and finds this commit that adds explicit notes to these
> manual pages via "git blame", s/he would not be dissuaded from
> making things better.  Such an update may make it warn when
> core.logallrefupdates is not set to false (and continue to ignore
> the command line option), or it may make the command line option
> actually override the configured default.

Yeah, I'd consider it more of a "known bug" or "known limitation" than anything.

Those can go in a separate section, but they're probably more likely to be read when supplied next to the actual option.

Show 8 quoted lines
> With such an update to the log message, I think the patch looks
> good.
> [...]
> > @@ -91,6 +91,7 @@ OPTIONS
> >  	based sha1 expressions such as "<branchname>@\{yesterday}".
> >  	Note that in non-bare repositories, reflogs are usually
> >  	enabled by default by the `core.logallrefupdates` config option.
> > +	The negated form `--no-create-reflog` is silently ignored.

This might be nitpicking, but it's _not_ ignored. It still negates an earlier "--create-reflog". It is only that it does not override the decision to create a reflog caused by the setting of core.logallrefupdates.

-Peff
Previous: Junio C HamanoNext: Junio C Hamano
Message 3 of 10 in “doc: add note about ignoring --no-create-reflog”
  1. doc: add note about ignoring --no-create-reflogcornelius.weig@tngtech.com, Feb 1, 2017
  2. Junio C HamanoFeb 1, 2017
  3. Jeff KingFeb 1, 2017
  4. Junio C HamanoFeb 1, 2017
  5. Cornelius WeigFeb 1, 2017
  6. Jeff KingFeb 1, 2017
  7. Cornelius WeigFeb 1, 2017
  8. Junio C HamanoFeb 1, 2017
  9. Jeff KingFeb 1, 2017
  10. Junio C HamanoFeb 1, 2017

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.