如何在git bash /命令行中使用Notepad ++ Compare作为diff工具? [英] How do I use Notepad++ Compare as the diff tool in git bash/command line?

查看:259
本文介绍了如何在git bash /命令行中使用Notepad ++ Compare作为diff工具?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法在gitbash中更改默认的diff工具?

这篇文章似乎暗示这是可能的,但他们没有提供命令行示例。链接:从比较插件的命令行运行NotePad ++显示比较结果

解决方案

由于Notepad ++的官方diff插件似乎是 uph0 / compare ,一个可能的设置可能是:

  $ git config --global --add diff.guitool nppdiff 
$ git config --global --add difftool.nppdiff.pathC :/ Program Files / Notepad ++ / plugins / ComparePlugin / compare.exe
$ git config --global --add difftool.nppdiff.trustExitCode false


Is there any way to change the default diff tool in gitbash?

This post seems to suggest it is possible but they provided no command line examples. Link: Running NotePad++ from Command line with Compare Plugin showing compare result

解决方案

Since the official diff plugin for Notepad++ seems to be uph0/compare, a possible setting could be:

$ git config --global --add diff.guitool nppdiff
$ git config --global --add difftool.nppdiff.path "C:/Program Files/Notepad++/plugins/ComparePlugin/compare.exe"
$ git config --global --add difftool.nppdiff.trustExitCode false

这篇关于如何在git bash /命令行中使用Notepad ++ Compare作为diff工具?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆