3月 202016
 

在mac上,beyond compare默认没有安装命令行,需要通过如下方式安装命令行:

其中,命令行有两个命令,如下:

/usr/local/bin/bcomp:
Launches comparison and waits for it to complete.

/usr/local/bin/bcompare:
Launches comparison and returns immediately.

 

配置diff工具和配置merge工具几乎没有太大差别,这里以diff为例

首先,看看git支持哪些diff工具:

其中:

  1. 后面的工具能用,但是当前不可用;大概意思是,下面这些工具都是图形化的,需要窗口环境,但是,当前是一个terminal-only的会话,他们会失败的。 (但是,我下面要使用的bc就是图形化的呀?)
  2. bc是啥? 就是 beyond compare; 为啥还分bc和bc3?(估计是参数定义不同吧,我们配置工具的时候也不需要指定参数,肯定是git已经帮我们配置好了)
  3. git没有内置这些工具,只是默认有这些工具的相关配置
  4. 我们可以直接通过命令行参数指定使用哪个工具,如下,指定vimdiff:
    git difftool -t vimdiff
  5. 我们可以通过 -x 选项指定自定义的命令,参数就是要比较的两个文件,这样我可以使用git没有内置支持的一些工具了

配置方法, git difftool –help

参考:https://gist.github.com/jfromaniello/9207698

 Posted by at 上午 12:41

 Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">

(required)

(required)

此站点使用Akismet来减少垃圾评论。了解我们如何处理您的评论数据