Thread (8 messages) flat view 8 messages, 3 authors, 2016-06-15

Re: gitweb.cgi history not shown

From: Linus Torvalds <torvalds@osdl.org>
Date: 2016-06-15 22:42:29

I just like talking to myself.

On Sun, 11 Jun 2006, Linus Torvalds wrote:
	git-rev-list --all | git-diff-tree -p -- <filename>
That obviously wants a "--stdin" argument to git-diff-tree, and I might as 
well point out that it has a few other differences to doing this with the 
"--no-simplify-history" flag:

 - git-diff-tree obviously doesn't show merges normally, and when it does, 
   it would show only merges that change the file. In contrast, the "git 
   log" approach would show all merges that are part of the resulting 
   history (which, since you don't simplify merges, is _all_ of them).

 - the extra flag to "git log" approach allows "--parents" to work, ie the 
   stretches of commits in between merges would have their parents 
   rewritten, so that the history would be a unified whole, and you can 
   use qgit/gitk to show the result. The above pipeline obviously cannot 
   do that, since doing the filename limiter in git-diff-tree means that 
   it doesn't ever even _see_ the "history" part, it's just doing it one 
   commit at a time.

That concludes my monologue on the matter, I hope. If somebody wants to 
condense the issue of "show all history" vs "show how we got to this 
state" and add it to the Wiki FAQ thing, that would probably be good.

		Linus
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help