2014-03-07 58 views
2

我想設置trustExitCode爲false,並keepTemporaries爲true,但它不工作...我不underestand原因。這裏是我的~/.gitconfig爲什麼我的Git mergetool配置不起作用?

[merge] 
     conflictstyle = diff3 
     tool = p4merge 
[mergetool] 
     keepTemporaries = true 
     keepBackup = true 
     trustExitCode = false 
[mergetool "p4merge"] 
     trustExitCode = false 
     keepTemporaries = true 
[mergetool "mymeld"] 
     cmd = meld --diff $BASE $LOCAL --diff $BASE $REMOTE --diff $LOCAL $MERGED $REMOTE 
     trustExitCode = false 
     keepTemporaries = true 
[mergetool "myp4merge"] 
     cmd = p4merge $BASE $LOCAL $REMOTE $MERGED 
     trustExitCode = false 
     keepTemporaries = true 

當我節省一些修改,無論是與p4merge,myp4merge或mymeld,Git不會問我的預期「是合併成功[Y/N]?」,不離開file.BASE,file.REMOTE,...

我無法找到錯誤...

回答

0

我想你應該添加path設置mergetool XYZ配置,而不是cmd。這是我自己的設置,可以正常工作。

[mergetool "kdiff3"] 
    path = PATH_TO_KDIFF3 
    trustExitCode = false 
    keepTemporaries = true 
[mergetool] 
    keepBackup = true 
[merge] 
    tool = kdiff3 
    conflictstyle = diff3 
+0

這似乎並不爲我工作... – janou195