All of lore.kernel.org
 help / color / mirror / Atom feed
From: Felipe Contreras <felipe.contreras@gmail.com>
To: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>, git@vger.kernel.org
Cc: Peter Zijlstra <peterz@infradead.org>,
	Thomas Gleixner <tglx@linutronix.de>,
	linux-kernel <linux-kernel@vger.kernel.org>,
	Jiri Kosina <trivial@kernel.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Subject: RE: git feature request: git blame --ignore-cleanup/--ignore-trivial
Date: Wed, 02 Jun 2021 16:16:54 -0500	[thread overview]
Message-ID: <60b7f54697fda_16925f2083d@natae.notmuch> (raw)
In-Reply-To: <30399052.5964.1622647235870.JavaMail.zimbra@efficios.com>

Mathieu Desnoyers wrote:
> Perhaps a new git blame "--ignore-trivial" and/or "--ignore-cleanup" could solve
> this by filtering out "trivial" and "cleanup" patches from the history it considers.

While this feature would be a good addition, more often than not I need
to look behind the latest commit regardless of whether or not it's a
trivial one.

So what I often end up doing is a `git blame --incremental`:

  git blame --incremental -L100,+6 file.c | grep -o -e '^[0-9a-f]\{40\}'

This can be fed to `git log --stdin --oneline --no-walk` for more
user-friendliness.

Of course you could just do:

  git log -L100,+6:file.c --oneline --no-patch

But for some reason that's much slower on my system.

Cheers.

-- 
Felipe Contreras

  parent reply	other threads:[~2021-06-02 21:16 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-02 15:20 git feature request: git blame --ignore-cleanup/--ignore-trivial Mathieu Desnoyers
2021-06-02 15:29 ` Al Viro
2021-06-02 19:41   ` Taylor Blau
2021-06-03 15:33     ` Mathieu Desnoyers
2021-06-03 10:13   ` David Sterba
2021-06-02 19:37 ` Jeff King
2021-06-02 21:16 ` Felipe Contreras [this message]
2021-06-03 10:23 ` David Sterba

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=60b7f54697fda_16925f2083d@natae.notmuch \
    --to=felipe.contreras@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mathieu.desnoyers@efficios.com \
    --cc=peterz@infradead.org \
    --cc=tglx@linutronix.de \
    --cc=trivial@kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.