git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Jeff King <peff@peff.net>
Cc: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>,
	"heapcrash heapcrash" <heapcrash@gmail.com>,
	git@vger.kernel.org
Subject: Re: Enhancing --show-function and --function-context in default configurations
Date: Mon, 02 Aug 2021 10:06:53 -0700	[thread overview]
Message-ID: <xmqqmtpzwzbm.fsf@gitster.g> (raw)
In-Reply-To: <YQgahVPT8g0+U1B3@coredump.intra.peff.net> (Jeff King's message of "Mon, 2 Aug 2021 12:17:09 -0400")

Jeff King <peff@peff.net> writes:

> On Mon, Aug 02, 2021 at 10:45:25AM +0200, Ævar Arnfjörð Bjarmason wrote:
>
>> I would like to see us have a setting to turn these on by default, but
>> think it would be better to make that a diff.* config setting to put
>> into ~/.gitconfig, i.e. we'd extend git itself to know about a list of
>> extensions for the given userdiff drivers, and use them when rendering
>> diffs.
>
> A long time ago we discussed doing this. The relevant thread is:
>
>   https://lore.kernel.org/git/20111216110000.GA15676@sigill.intra.peff.net/
>
> which references a few others:
>
>   https://lore.kernel.org/git/4E569F10.8060808@panasas.com/
>
>   https://lore.kernel.org/git/4E6E928A.6080003@sunshineco.com/
> ...

Thanks for pointers.

One good suggestion given there was to use diff=c and diff=perl in
our own .gitattributes to use the patterns ourselves, which we seem
to have been doing just fine ;-)

As long as the default built-in ones are

 (1) at least 90% of the time improvement over, or at least is not
     broken compared to, the unconfigured case, and

 (2) at the lowest priority that users can easily countermand for
     the rest 10% cases

I do not think it is too bad to resurrect the old patches from these
threads.

Thanks.



  reply	other threads:[~2021-08-02 17:06 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-01 21:40 Enhancing --show-function and --function-context in default configurations heapcrash heapcrash
2021-08-02  2:21 ` Junio C Hamano
2021-08-02  8:45 ` Ævar Arnfjörð Bjarmason
2021-08-02 16:17   ` Jeff King
2021-08-02 17:06     ` Junio C Hamano [this message]
2021-08-03  2:34       ` heapcrash heapcrash
2021-08-03 14:55         ` 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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=xmqqmtpzwzbm.fsf@gitster.g \
    --to=gitster@pobox.com \
    --cc=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=heapcrash@gmail.com \
    --cc=peff@peff.net \
    /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.
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 NNTP newsgroup(s).