Re: "git-diff-tree -R A B == git-diff-tree B A"?
- From
Linus Torvalds <torvalds@osdl.org>
- Date
- May 20, 2005, 15:57 UTC
- Message-ID
- <Pine.LNX.4.58.0505200855120.2206@ppc970.osdl.org>
- In-Reply-To
- <Pine.LNX.4.58.0505200844090.2206@ppc970.osdl.org>
On Fri, 20 May 2005, Linus Torvalds wrote:
Show 7 quoted lines
> > The only correct way to do name sorting is the one that fsck does in > "verify_order()". To realize why, you need to realize that "A" (the > directory) sorts _after_ a filename "A file", because '/' sorts after ' '. > > In contrast, "A" (the directory) sorts _before_ "ABBA" (the band), because > '/' sorts before 'B'.
Btw, in case you wonder: the real problem is that we use "cache_name_compare()" on a directory name. The function is (as the name says) designed for full pathnames, not the diff-tree kind of possibly partial basenames.
Linus