Saturday, April 13, 2013

Visual merge tools to resolve conflicts

Git visual merge in conflict:
http://www.gitguys.com/topics/merging-with-a-gui/

Meld - Works fine, but not intuitive.


sudo apt-get install meld
git mergetool -t meld
Main idea is to merge left and right versions to middle version and press Cntl+s.


kdiff3 - more intuitive and more settings.

sudo apt-get install kdiff3
git mergetool -t kdiff3


After that launch "git clean -f" to remove all un-tracked files.
It also possible to adjust git to avoid temp files creation
"git config --global mergetool.keepBackup false"

of adjust  your merge tool:
- Meld - does not have that feature
- kdiff3's settings are set to not create a backup:
Configure/Options => Directory Merge => Backup Files (*.orig)

No comments:

Post a Comment