From: Jeff King <peff@peff.net>
To: Derrick Stolee via GitGitGadget <gitgitgadget@gmail.com>
Cc: git@vger.kernel.org, me@ttaylorr.com,
Derrick Stolee <dstolee@microsoft.com>
Subject: Re: [PATCH] revision: --include-diversions adds helpful merges
Date: Wed, 8 Apr 2020 14:48:43 -0400 [thread overview]
Message-ID: <20200408184843.GA1963695@coredump.intra.peff.net> (raw)
In-Reply-To: <pull.599.git.1586308923544.gitgitgadget@gmail.com>
On Wed, Apr 08, 2020 at 01:22:03AM +0000, Derrick Stolee via GitGitGadget wrote:
> The default file history simplification of "git log -- <path>" or
> "git rev-list -- <path>" focuses on providing the smallest set of
> commits that first contributed a change. The revision walk greatly
> restricts the set of walked commits by visiting only the first
> TREESAME parent of a merge commit, when one exists. This means
> that portions of the commit-graph are not walked, which can be a
> performance benefit, but can also "hide" commits that added changes
> but were ignored by a merge resolution.
> [...]
Thanks for a really great description of the problem.
Playing around with the patch, I found one curiosity. Try this:
git log --graph --oneline origin -- GIT-VERSION-GEN >old
git log --graph --oneline --include-diversions \
origin -- GIT-VERSION-GEN >new
diff -u old new
The first hunk has:
@@ -70,6 +70,7 @@
* 20769079d2 Git 2.12-rc2
* 5588dbffbd Git 2.12-rc1
* 6e3a7b3398 Git 2.12-rc0
+* 0a45050a14 Merge branch 'rj/git-version-gen-do-not-force-abbrev'
* a7659747c2 GIT-VERSION-GEN: do not force abbreviation length used by 'describe'
* 8d7a455ed5 Start post 2.11 cycle
* 454cb6bd52 Git 2.11
which makes sense. That merge brought in a7659747c2, and the other side
hadn't touched it. But I can't tell from the output how the two are
related. Nor can I just add "-p" to the invocation; after we've
simplified, it has only a single parent, but it's TREESAME to that
parent. So it has no diff.
I actually think the most descriptive output here would be something
like:
* 6e3a7b3398 Git 2.12-rc0
* 0a45050a14 Merge branch 'rj/git-version-gen-do-not-force-abbrev'
|\
| * a7659747c2 GIT-VERSION-GEN: do not force abbreviation length used by 'describe'
|/
* Start post 2.11 cycle
I.e., leaving both parents intact for a "diversion" merge. But maybe
that would have secondary effects in other places.
-Peff
next prev parent reply other threads:[~2020-04-08 18:48 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-08 1:22 Derrick Stolee via GitGitGadget
2020-04-08 1:30 ` Junio C Hamano
2020-04-08 1:39 ` Derrick Stolee
2020-04-08 15:28 ` Derrick Stolee
2020-04-08 19:46 ` Junio C Hamano
2020-04-08 20:05 ` Jeff King
2020-04-08 20:22 ` Derrick Stolee
2020-04-08 21:35 ` Junio C Hamano
2020-04-08 23:59 ` Derrick Stolee
2020-04-09 0:08 ` Junio C Hamano
2020-04-09 11:52 ` Derrick Stolee
2020-04-09 14:28 ` Philip Oakley
2020-04-09 15:56 ` Junio C Hamano
2020-04-09 17:20 ` Derrick Stolee
2020-04-09 18:24 ` Jeff King
2020-04-09 18:55 ` Junio C Hamano
2020-04-09 19:21 ` Jeff King
2020-04-08 2:13 ` brian m. carlson
2020-04-08 18:48 ` Jeff King [this message]
2020-04-09 0:01 ` [PATCH v2] " Derrick Stolee via GitGitGadget
2020-04-10 12:19 ` [PATCH v3] revision: --show-pulls " Derrick Stolee via GitGitGadget
2020-04-10 20:06 ` Junio C Hamano
2020-04-10 21:43 ` Derrick Stolee
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=20200408184843.GA1963695@coredump.intra.peff.net \
--to=peff@peff.net \
--cc=dstolee@microsoft.com \
--cc=git@vger.kernel.org \
--cc=gitgitgadget@gmail.com \
--cc=me@ttaylorr.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.
Code repositories for project(s) associated with this 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).