如何在Windows上使用git mintty mingw获得彩色输出?

我已经安装了官方的 Windows git发行版,我安装了一个最近的mingw,并进入了那个薄荷终端.然后我将我的git安装复制到这个mingw安装中,现在它可以在内部工作.我唯一的问题是git输出没有着色.我怀疑这是因为windows git端口试图使用windows控制台颜色thingie而不是mintty能够解释的ANSI颜色代码.是否有可能让git使用ANSI颜色代码

(我之前尝试过cygwin设置,但性能非常非常糟糕,我找不到任何解决方案).

git-config

If this is set to always,git-diff(1),git-log(1),and git-show(1) will use color for all patches. If it is set to true or auto,those commands will only use color when output is to the terminal. Defaults to false.

它看起来像git不是薄荷作为终端.对我来说总是使用而不是真/自动帮助:

[color]
  status = always

通过向diff命令添加–color标志来强制颜色(使用diff = true):

git diff --color

相关文章

Windows2012R2备用域控搭建 前置操作 域控主域控的主dns:自...
主域控角色迁移和夺取(转载) 转载自:http://yupeizhi.blo...
Windows2012R2 NTP时间同步 Windows2012R2里没有了internet时...
Windows注册表操作基础代码 Windows下对注册表进行操作使用的...
黑客常用WinAPI函数整理之前的博客写了很多关于Windows编程的...
一个简单的Windows Socket可复用框架说起网络编程,无非是建...