From: Max Kirillov <max@max630.net>
To: Jeff King <peff@peff.net>
Cc: Junio C Hamano <gitster@pobox.com>,
Stephen Connolly <stephen.alan.connolly@gmail.com>,
Git Mailing List <git@vger.kernel.org>
Subject: Re: [Feature Request] git blame showing only revisions from git rev-list --first-parent
Date: Sun, 18 Oct 2015 14:38:57 +0300 [thread overview]
Message-ID: <20151018113857.GA5722@wheezy.local> (raw)
In-Reply-To: <20150915100538.GA21831@sigill.intra.peff.net>
On Tue, Sep 15, 2015 at 06:05:39AM -0400, Jeff King wrote:
> It seems like nobody is actually that interested in what "blame
> --first-parent --reverse" does in the first place, though, and there's
> no reason for its complexity to hold up vanilla --first-parent. So what
> do you think of:
...
> Combining "--reverse" with "--first-parent" is more
> complicated, and will probably involve cooperation from
> revision.c. Since the desired semantics are not even clear,
> let's punt on this for now, but explicitly disallow it to
> avoid confusing users (this is not really a regression,
> since it did something nonsensical before).
Hi.
I might be late for this discussion, but I seem to have
a case when blame --reverse --first-parent seems to work.
Consider the folowing history (from left ro right):
+-----------------D1-+
+--->C1------>C2-+ \
/ \ \
A0->A1-------->A2---..-->A3-->A4-->A5
\ /
+->B1-->B2-+
, and a line was removed in B2. Then, blame --reverse
returns D1 for this line, which is, while technically
correct, absolutely useless to find real place where the
line was removed. But blame --reverse --first-parent seems
to return A1, which is much more useful and actually what
I would expect to return. I tried it recently with
2.3-something and it seems to work as expected.
Was it the behavior you mentioned as nonsensical or you have
some other examples?
So please may I ask to not kill this completely. As about
the issue mentioned by Junio, it could fail loudly if the
requested range is not a first-parent chain.
--
Max
next prev parent reply other threads:[~2015-10-18 11:39 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-11 10:47 [Feature Request] git blame showing only revisions from git rev-list --first-parent Stephen Connolly
2015-09-11 14:01 ` Jeff King
2015-09-11 15:31 ` Stephen Connolly
2015-09-11 16:35 ` Junio C Hamano
2015-09-11 19:06 ` Junio C Hamano
2015-09-12 3:30 ` Jeff King
2015-09-12 8:29 ` Junio C Hamano
2015-09-12 22:09 ` Philip Oakley
2015-09-13 10:07 ` Jeff King
2015-09-14 5:19 ` Junio C Hamano
2015-09-15 10:05 ` Jeff King
2015-09-16 1:14 ` Junio C Hamano
2015-09-16 17:37 ` Jeff King
2015-09-17 17:03 ` Junio C Hamano
2015-10-18 11:38 ` Max Kirillov [this message]
2015-10-18 17:41 ` Junio C Hamano
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=20151018113857.GA5722@wheezy.local \
--to=max@max630.net \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=peff@peff.net \
--cc=stephen.alan.connolly@gmail.com \
/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).