From: Junio C Hamano Date: Mon, 10 Apr 2006 23:42:44 GMT Subject: Re: [PATCH] git log [diff-tree options]... Message-ID: <7vodz980az.fsf@assigned-by-dhcp.cox.net> In-Reply-To: Linus Torvalds writes: > On Sun, 9 Apr 2006, Junio C Hamano wrote: >> >> And this makes "git log" to take common diff-tree options, so >> that it can be used as "git whatchanged". > > I wonder... This all looks fine, but there are actually two different > "diffs" that can be shown for "git log --diff ": > > - the whole diff for a commit > > - the path-limited diff > > and I think we'd likely want to have some way to select the output. > Probably with the path-limited diff being the default (that's what > "git-whatchanged" does), but perhaps with "--full-diff" showing the whole > commit diff (which is what "gitk" does). Yes, but it turns out it is a bit tricky, given that the way tree-diff.c is written it pretty much assumes the same pathspec is used for diff operation during the lifetime of the process. I think we should move (nr_paths, pathlens and paths) to struct diff_options. Two patches to follow shortly.