Re: Git log follow question
- From
Jeff King <peff@peff.net>
- Date
- May 25, 2010, 09:31 UTC
- Message-ID
- <20100525093140.GA32460@coredump.intra.peff.net>
- In-Reply-To
- <alpine.LFD.2.00.1005140730030.3711@i5.linux-foundation.org>
On Fri, May 14, 2010 at 07:50:26AM -0700, Linus Torvalds wrote:
Show 11 quoted lines
> I'm pretty sure I mentioned about this exact issue when I posted the > original follow patches, and it basically boils down to: "--follow" is a > total hack, and does _not_ use the regular commit filtering function, and > as a result, fancy things like "--parent" don't really work well with it. > > [...] > > And no, I'm unlikely to look at it. Sorry. I have used --follow > occasionally, but it's a hack to see "ok, there it got renamed". It would > be nice if "gitk --follow <pathname>" worked properly, but it's just not > something I care very much about.
Thanks for the input. I took a look at it myself and it is a bit more complex than just turning on pruning. I have a prototype --follow that handles arbitrary pathspecs instead of single files; instead of replacing the single-file pathspec, it just widens the pathspec as it traverses history. That eliminates some of the issues, but I am still getting some odd results from --parents.
So I am giving up for now, as it is not something I care that much about, either (though multiple-file --follow is). However, Bo Yang, one of the GSoC students, is planning on working on it as part of his line-level history browsing project. So we'll see what comes of that.
-Peff