Sascha Peilicke [off-list ref] writes:
try the same with
git diff > foo
git diff > foo && cat foo
=> no color.
git diff --no-color > foo && cat foo
=> no color either
git diff --color=always > foo && cat foo
=> colors.
Again, just the expected behavior.
If it helps:
$ uname -a
Linux bauges 2.6.36-686 #1 SMP PREEMPT Fri Nov 5 10:35:38 CET 2010 i686 GNU/Linux
$ git --version
git version 1.7.4.rc1.17.ge7ece
--
Matthieu Moy
http://www-verimag.imag.fr/~moy/