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

Re: [PATCH] status: respect advice.statusHints for ahead/behind advice

From
Matthieu Moy <matthieu.moy@grenoble-inp.fr>
Date
Dec 3, 2012, 08:49 UTC
Message-ID
<vpqtxs31pxf.fsf@grenoble-inp.fr>
In-Reply-To
<20121203061656.GA20164@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 5 quoted lines
> If the user has unset advice.statusHints, we already
> suppress the "use git reset to..." hints in each stanza. The
> new "use git push to publish..." hint is the same type of
> hint. Let's respect statusHints for it, rather than making
> the user set yet another advice flag.
Sorry, I should have made this in the patch.
With or without my suggestion below,
Acknowledged-by: Matthieu Moy <Matthieu.Moy@imag.fr>
> I left "git checkout" alone, though I'd also like to turn it off there,
> too. Should it get a separate advice option there? Should it simply
> respect statusHints (it seems odd because I know that "status" there
> means "git status", not "hints about the status of your repo")?

I'd respect the same statusHint indeed. It's the same message, so I think the same category of users will want to disable it. The name "statusHint" may not be the ideal one, but if you see the messages in "git checkout" as an excerpt of "git status", it actually makes sense.

As a nice side effect, it also makes the code/patch simpler (no need to add the "advice" argument).

-- 
Matthieu Moy
http://www-verimag.imag.fr/~moy/
Previous: Jeff KingNext: Junio C Hamano
Message 2 of 5 in “status: respect advice.statusHints for ahead/behind advice”
  1. status: respect advice.statusHints for ahead/behind adviceJeff King, Dec 3, 2012
  2. Matthieu MoyDec 3, 2012
  3. Junio C HamanoDec 3, 2012
  4. Jeff KingDec 3, 2012
  5. Matthieu MoyDec 4, 2012

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.