From: Duy Nguyen <pclouds@gmail.com>
To: Jeff King <peff@peff.net>
Cc: "René Scharfe" <l.s.r@web.de>, "Tom Hale" <tom@hale.ee>,
git <git@vger.kernel.org>, "Junio C Hamano" <gitster@pobox.com>
Subject: Re: %C(auto) not working as expected
Date: Tue, 25 Oct 2016 19:52:21 +0700 [thread overview]
Message-ID: <CACsJy8B_AQxm1=vF8i4FPtinq0id1QZPrqp9vvAmAgUns_kgGg@mail.gmail.com> (raw)
In-Reply-To: <20161010142818.lglwrxpks6l6aqrm@sigill.intra.peff.net>
On Mon, Oct 10, 2016 at 9:28 PM, Jeff King <peff@peff.net> wrote:
> On Mon, Oct 10, 2016 at 04:26:18PM +0700, Duy Nguyen wrote:
>
>> > If we do a revamp of the pretty-formats to bring them more in line with
>> > ref-filter (e.g., something like "%(color:red)") maybe that would be an
>> > opportunity to make minor adjustments. Though, hmm, it looks like
>> > for-each-ref already knows "%(color:red)", and it's unconditional.
>> > <sigh> So perhaps we would need to go through some deprecation period or
>> > other transition.
>>
>> We could add some new tag to change the behavior of all following %C
>> tags. Something like %C(tty) maybe (probably a bad name), then
>> discourage the use if "%C(auto" for terminal detection?
>
> Yeah, adding a "%C(enable-auto-color)" or something would be backwards
> compatible and less painful than using "%C(auto)" everywhere. I do
> wonder if anybody actually _wants_ the "always show color, even if
> --no-color" behavior. I'm having trouble thinking of a good use for it.
>
> IOW, I'm wondering if anyone would disagree that the current behavior is
> simply buggy.
Silence in two weeks. I vote (*) making %(<color-name>) honor --color
and turning the %(auto, no-op, for both log family and for-each-ref.
We could keep old behavior behind some environment variable if it's
not much work so it keeps working while people come here and tell us
about their use cases.
(*) I know.. voting is not how things work around here, unless you
vote with patches, but I can't take on another topic.
> Reading the thread at:
>
> http://public-inbox.org/git/7v4njkmq07.fsf@alter.siamese.dyndns.org/
>
> I don't really see any compelling reason against it (there was some
> question of which config to use, but we already answered that with
> "%C(auto)", and use the value from the pretty_ctx).
>
> -Peff
--
Duy
next prev parent reply other threads:[~2016-10-25 12:52 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-10-09 5:43 %C(auto) not working as expected Tom Hale
2016-10-09 6:47 ` René Scharfe
2016-10-09 10:04 ` Tom Hale
2016-10-09 13:24 ` René Scharfe
2016-10-09 23:46 ` Jeff King
2016-10-10 9:26 ` Duy Nguyen
2016-10-10 14:28 ` Jeff King
2016-10-10 15:15 ` [PATCH] pretty: respect color settings for %C placeholders Jeff King
2016-10-10 17:09 ` René Scharfe
2016-10-10 17:42 ` Jeff King
2016-10-10 19:59 ` René Scharfe
2016-10-10 20:04 ` Jeff King
2016-10-10 18:52 ` Junio C Hamano
2016-10-10 18:59 ` Jeff King
2016-10-10 20:54 ` Jeff King
2016-10-11 10:59 ` Duy Nguyen
2016-10-25 12:52 ` Duy Nguyen [this message]
2016-10-25 12:58 ` %C(auto) not working as expected Jeff King
2016-10-25 13:02 ` Duy Nguyen
2016-10-10 20:52 ` René Scharfe
2016-10-10 20:55 ` Jeff King
2016-10-11 3:41 ` [PATCH v2] pretty: fix document link for color specification René Scharfe
2016-10-11 4:45 ` Jeff King
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CACsJy8B_AQxm1=vF8i4FPtinq0id1QZPrqp9vvAmAgUns_kgGg@mail.gmail.com' \
--to=pclouds@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=l.s.r@web.de \
--cc=peff@peff.net \
--cc=tom@hale.ee \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).