Github风格分裂在命令行上 [英] Github style split diffs on a command-line

查看:145
本文介绍了Github风格分裂在命令行上的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Github在9月份推出了分歧比较。有没有什么办法可以在命令行上看到?

解决方案

典型的命令行通常不够宽一种比较。请注意,大部分Git都是为80个字符宽的终端而构建的。所以你每边有大约35个字符;我怀疑这是有帮助的(我已经在更广泛的终端上阅读统一差异时遇到问题)。

然而,Git允许您使用 diff tools ,这些外部程序可以执行任何你喜欢的操作。例如,您可以在Windows上使用诸如 WinMerge 之类的东西,默认情况下使用分割视图。还有很多其他的程序,对于每个平台,通常每个diff程序都可以设置为使用Git。


Github introduced split diffs in September. Is there any way to see that on a command-line?

解决方案

A typical command line is usually not wide enough to handle this kind of comparison. Note that most of Git is built for 80 character wide terminals. So you would have about ~35 characters per side; I doubt that’s helpful (I already have problems reading unified diffs on a much wider terminal).

Git however gives you the ability to use diff tools, external programs that can do whatever diff you prefer. For example, you could use something like WinMerge on Windows, which uses a split view by default. There are many other programs for it, for every platform, and usually every diff program can be set up to work with Git.

这篇关于Github风格分裂在命令行上的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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