Disable automatic merging files when pulling from another branch

时间:2015-10-30 23:31:48

标签: git atlassian-sourcetree tortoisegit

How do you stop TortoiseGit and/or SourceTree from performing an automatic merge when you pull from another branch? I want to manually merge (with KDiff3 or whatever external diff/merge program) all files that have been changed in both the checked out branch and the branch I'm pulling from. Apparently, merging is done automatically (and badly) by default, and it completely messed up my project files.

1 个答案:

答案 0 :(得分:0)

  1. 将KDiff3设置为diff / merge的外部程序
  2. 比较修订
  3. 区分每个文件并手动合并
  4. 外部程序设置:https://tortoisegit.org/docs/tortoisegit/tgit-dug-settings.html

    使用KDiff3进行差异:

    C:\Path-To\kdiff3.exe %base %mine --L1 %bname --L2 %yname

    与KDiff3合并:

    C:\Path-To\kdiff3.exe %base %mine %theirs -o %merged --L1 %bname --L2 %yname --L3 %tname