Re: [WIP PATCH] Manual rename correction
- From
Nguyen Thai Ngoc Duy <pclouds@gmail.com>
- Date
- Aug 1, 2012, 06:34 UTC
- Message-ID
- <CACsJy8Aa_YohFEApGQxL5086vOviAKBc1AB0QyWVsda6byrYzg@mail.gmail.com>
- In-Reply-To
- <7v4nongn3e.fsf@alter.siamese.dyndns.org>
On Wed, Aug 1, 2012 at 1:09 PM, Junio C Hamano <gitster@pobox.com> wrote:
Show 10 quoted lines
> Nguyen Thai Ngoc Duy <pclouds@gmail.com> writes: > >> Yes. This is probably cosmetics only, but without path information, we >> leave it to chance to decide which A to pair with B and C (in the >> A->B, A->C case above). Wrong path might lead to funny effects (i'm >> thinking of git log --follow). > > Isn't that why <A,B> and <A,C> can have different scores per object > name pair? And if you mean by B and C the paths not object names, > and the blob at B and C are indeed identical, why would it matter?
I don't see how scores affect that. Suppose I have two trees and a rename-cache file:
$ git ls-tree -r HEAD^ 100644 blob d00491 path1/foo 100644 blob d00491 path2/bar $ git ls-tree -r HEAD 100644 blob 0cfbf0 path1/fooo 100644 blob 00750e path2/barr $ cat rename-cache d00491 0cfbf0 <score 1> d00491 00750e <score 2>
How can I be sure "git diff HEAD^!" will rename path1/foo => path1/fooo and path2/bar => path2/barr, not path1/foo => path2/barr and path2/bar => path1/fooo?
-- Duy