Feature request: Configurable branch colors in git status --short --branch

2 messages, 2 authors, 2017-04-16 · open the first message on its own page

Feature request: Configurable branch colors in git status --short --branch

From: Stephen Kent <hidden>
Date: 2017-04-15 20:01:04

It would be nice if the branch, remote tracking branch, and branch 
commit comparison count colors in git status --short --branch were 
configurable like the other git status colors.

Example command output:

$ git status --short --branch
## master...origin/master [ahead 1]
M  README.md
M  wrapper.c
 M ws.c
 M wt-status.c

In the above example, "master", "origin/master", and "1" (in "ahead 1") 
use git's standard red and green colors. I have configured the staged 
and unstaged modification markers (the M's) to use brighter green and 
red, and I would like to configure the branch info to also use those 
brighter colors. However, there is currently no option (color slot for 
git status in git config) to change the branch colors in 
git status --short --branch.

(See the attached screenshot or http://i.imgur.com/evqgaRd.png to see 
the colors I am talking about.)

Stephen

Re: Feature request: Configurable branch colors in git status --short --branch

From: Jeff King <hidden>
Date: 2017-04-16 06:44:24

On Sat, Apr 15, 2017 at 01:00:51PM -0700, Stephen Kent wrote:
It would be nice if the branch, remote tracking branch, and branch commit
comparison count colors in git status --short --branch were configurable
like the other git status colors.
That seems like a reasonable thing to want.

I think the infrastructure is all there, and it would just need an
update to builtin/commit.c:parse_status_slot() to map the color.status.*
names into the {LOCAL,REMOTE}_BRANCH enum values.

Want to try your hand at a patch?

-Peff
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help