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

Re: [PATCH] git status: display current branch name in color

From
Jeff King <peff@peff.net>
Date
Jan 18, 2010, 02:32 UTC
Message-ID
<20100118023255.GC6831@coredump.intra.peff.net>
In-Reply-To
<d2e97e801001162031n1dab2301k5a839846b3cc5d9d@mail.gmail.com>
On Sun, Jan 17, 2010 at 03:31:07PM +1100, Michael Wookey wrote:
Show 11 quoted lines
> > There is an existing highlight when the user is not on any branch.
> > Enhance this functionality to always provide the name of the current
> > branch in color.
> >
> > Signed-off-by: Michael Wookey <michaelwookey@gmail.com>
> > ---
> >  wt-status.c |   10 ++++++----
> >  wt-status.h |    3 ++-
> >  2 files changed, 8 insertions(+), 5 deletions(-)
> 
> Any thoughts on this?

I don't have an objection to the concept, but for it to be acceptable for inclusion in mainstream git, the color selection needs to be configurable (see builtin-commit.c:parse_status_slot) and documented (see Documentation/config.txt, color.status.<slot>).

And then we can decide what the _default_ color should be. Personally, I find it a bit distracting to change the color for something so mundane, and would be in favor of leaving it the same as the header color. But I will not argue too hard either way; I have no problem with setting my own config to make it invisible if others disagree. :)

-Peff
Previous: Michael Wookey
Message 3 of 3 in “git status: display current branch name in color”
  1. git status: display current branch name in colorMichael Wookey, Jan 15, 2010
  2. Michael WookeyJan 17, 2010
  3. Jeff KingJan 18, 2010

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.