Re: Show all branches and ahead/behind states

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, May 15, 2015 at 09:25:22AM -0500, Robert Dailey wrote:

> > It's spelled "%C(bold blue)" in the --pretty formats, but in
> > for-each-ref, it's "%(color:bold blue)". Unifying these is one of those
> > things that has been on the radar for a long time, but nobody has quite
> > gotten around to it.
> >
> Thanks Jeff! That definitely fixed it. I was not able to find a
> reference for this in the git docs, maybe I just overlooked it
> somewhere.

It's in "git help for-each-ref" (see the section on "FIELD NAMES").

> As a second query, is there a way to do column alignment? For example,
> I would like the ahead/behind status in one column, and the branch
> names left aligned in a 2nd column. I can't simply use tabs here since
> the length of column 1 may differ more greatly than a single tab
> character.

The "--pretty" format does have "%<" for doing printf-style alignment
(see the "PRETTY FORMATS" section of "git help log"). But "for-each-ref"
doesn't have any similar facility, as far as I know.

Again, this is something that it would be nice to fix.

-Peff
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]