前提是安装git(需要在环境path配置)和Beyond Compare
在path后面追加:
image.png
<meta charset="utf-8">
git 中添加 Beyond Compare作为 difftool和mergetool
difftool
1. 查看是否允许bc作为比较工具
git difftool --tool-help
返回:
image
包含 bc 、bc3、 bc4
所以可以可以配置
2. 配置difftool配置完成后,.gitconfig文件会自动增加以下截图配置
git config --global diff.tool bc4
git config --global difftool.bc4.path "C:\Program Files\Beyond Compare 4\BComp.exe"
.gitconfig文件中也已经配置好了(C:\Users\Administrator中找到.gitconfig文件)
image
3. 使用
在目标文件夹中出入cmd
image.png
输入指令git difftool或者明确指定某个文件git difftool index.js
image.png
自动打开beyond compare
image.png









网友评论