我试图使用 diffmerge 解决 git 中的一些合并冲突,我只是在我的机器上设置了 op,但它失败了并且出现了错误:
Hit return to start merge resolution tool (diffmerge):
C:\Program Files (x86)\Git/libexec/git-core/mergetools/diffmerge: line 136: diffmerge: command not found
merge of nextclue_input.cpp failed
以下是路径指向的文件的内容:
diff_cmd () {
"$merge_tool_path" "$LOCAL" "$REMOTE" >/dev/null 2>&1
}
merge_cmd () {
if $base_present
then
"$merge_tool_path" --merge --result="$MERGED" \
"$LOCAL" "$BASE" "$REMOTE"
else
"$merge_tool_path" --merge \
--result="$MERGED" "$LOCAL" "$REMOTE"
fi
status=$?
}
这是我为 diffmerge 设置 .gitconfig 文件的方式:
[merge]
tool = diffmerge
[mergetool "diffmerge"]
cmd = diffmerge --merge --result=$MERGED $LOCAL $BASE $REMOTE
trustExitCode = true
[diff]
tool = diffmerge
[difftool "diffmerge"]
cmd = diffmerge $LOCAL $REMOTE
不明白请帮忙。