git配置Beyond Compare
git 和 Beyond Compare自行安装
查看电脑当前系统支持的git diff/git merge插件
git difftool --tool-help
git mergetool --tool-help
如果你的运行结果中,没有出现bc/bc3/bc4的话,那基本上可以放弃了,电脑可能会不支持
配置git
其中路径改成自己的
git config --global diff.tool bc4
git config --global difftool.prompt false
git config --global difftool.bc4.cmd '"D:\Beyond Compare 4\Beyond Compare 4\BCompare.exe" "$LOCAL" "$REMOTE"'
git config --global merge.tool bc4
git config --global mergetool.prompt false
git config --global mergetool.bc4.cmd '"D:\Beyond Compare 4\Beyond Compare 4\BCompare.exe" "$LOCAL" "$REMOTE"
"$BASE" "$MERGED"'
git config --global mergetool.bc4.trustexitcode true
测试
# 提交时查看差异修改了什么
git difftool
# 合并时冲突修改
git mergetool
本文作者:makalo
本文链接:https://www.cnblogs.com/makalochen/p/16259143.html
版权声明:本作品采用知识共享署名-非商业性使用-禁止演绎 2.5 中国大陆许可协议进行许可。
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步