我想知道是否有人有一个技巧,当出现冲突时着色合并或rebase的输出。 我想特别颜色的文件名而行,例如第二行的位置:Git颜色合并/底线冲突
Auto-merging CMakeLists.txt
CONFLICT (content): Merge conflict in CMakeLists.txt
Failed to merge in the changes.
感谢
编辑:
使用Git别名和bash的功能,我可以这样写:
color-merge = "!f() { git merge --no-commit --stat $1| egrep --color 'CONFLICT .*|$'; }; f"
这将颜色的所有冲突行,但:
- 这是不可能改变通过合并
- 上有分支没有完成被跟踪
所以我在寻找的东西更强大的选项。
干杯
'git config --global color.ui auto'?! – 2012-03-13 15:04:11
我有颜色=总是,但不符合我的要求。 – Pluc 2012-03-13 18:23:52
从这个问题两年后,git仍然不支持CONFLICT上的颜色,这太疯狂了! – huocp 2014-07-25 01:09:39