Jon Aquino's Mental Garden

Engineering beautiful software jon aquino labs | personal blog

Friday, April 29, 2016

Please, please use a 3-way diff to resolve your git merge conflicts

I would like to stress the importance of using a 3-way diff to resolve merge conflicts. With a 3-way diff, you get:

                     Remote lines            Common ancestor lines            Local lines

It is very important to see the common ancestor, so that you can see exactly what changes were made to the remote file, and what changes were made to the local file. This gives you insight to see how you should combine the remote change with the local change.

I have made this 5-minute video to show you how to use a free 3-way diff called P4Merge (available for Windows and Mac) to resolve your conflicts:

http://screencast.com/t/jagvXzRI

To set up P4Merge with Git, just google for: p4merge git windows or p4merge git mac.

0 Comments:

Post a Comment

<< Home