Thread (9 messages) flat view 9 messages, 7 authors, 2016-06-15

Re: Parallel refactoring and git merge nightmare

From: Jeff King <hidden>
Date: 2016-06-15 22:53:33

On Wed, Apr 11, 2012 at 09:13:23AM -0700, Pap Lôrinc wrote:
I think the 
problem arises because git doesn't track
 moves, therefore I constantly get conflicts of type "local modified, 
remote deleted" (or even both deleted) when in fact it was only modified
 and moved, it could have been merged without conflicts (-> apply my 
changes and move the file to the new location).
Git does rename detection at the time of merge, and will apply changes
to the destination file. I'm not sure why this isn't working for you.
Some theories:

  1. Git may give up on finding renames if it is very computationally
     expensive. It will print a warning in that case, but you may miss
     it in the output. You might try:

        git config merge.renamelimit 0

     to turn off the limiting.

  2. Do your files actually look like renames? Git's inexact rename
     detection looks at the file content, and correlates removed and
     added files that have a high percentage of similar content. If most
     of the file ended up changed, then the pair is not considered a
     rename.

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