Re: [RFC PATCH] diff: do not use creation-half of -B as a rename target candidate

2015-02-02 Thread Junio C Hamano
Junio C Hamano gits...@pobox.com writes: * Here is what I am at the moment; I cannot quite explain (hence I cannot convince myself) why this is the right solution, but it seems to make the above sample case work without breaking any existing tests. It is possible that the tests

[RFC PATCH] diff: do not use creation-half of -B as a rename target candidate

2015-02-01 Thread Junio C Hamano
When a commit creates new file B by copying the contents of an existing file A and making a small edit and makes large edit to A, diff -M would not see any copying or renaming, because the file A appears in both preimage and postimage. The output ends up showing two large patches, one that adds

Re: [RFC PATCH] diff: do not use creation-half of -B as a rename target candidate

2015-02-01 Thread Stefan Beller
On 01.02.2015 19:18, Junio C Hamano wrote: When a commit creates new file B by copying the contents of an existing file A and making a small edit and makes large edit to A, This part is hard to parse When ... and making a small edit and makes a large edit So large or small? It's a bit hard to

Re: [RFC PATCH] diff: do not use creation-half of -B as a rename target candidate

2015-02-01 Thread Yue Lin Ho
A1 = I am file A. B1 is copied from A1, so B1 = I am file A. B1 changes to B2 = I am file B. A1 changes to A2 = file A is changed a lot, a lot, ..., a lot. At this moment, commit A2 and B2 files. -- View this message in context: