Git Diff (OSX) giving ESC[color errors
a/.vimrcESC[m
ESC[1m+++ b/.vimrcESC[m
ESC[[email protected]@ -1,12 +1,10 @@ESC[m
set path=~/codebase/builder-testESC[m
ESC[31m-set numberESC[m
ESC[31m-set background=darkESC[m
ESC[31m-colorscheme slateESC[m
</pre>
After reading a couple of blogs, it turns out that I was using ‘more’ as my core pager in my global .gitconfig instead of ‘less’.
All I needed to do is to change from:
[email protected]:~/codebase/config-files(master)> vim .gitconfig
[core]
pager = more
to
[email protected]:~/codebase/config-files(master)> vim .gitconfig
[core]
pager = less
I’ve been storing my global .gitconfig on github, so if you’re interested to find out how it looks like just head on over to my github :)
References:
[1] http://groups.google.com/group/github/browse_thread/thread/9fa7d5f8f2d8924f/5dcec3546cd825b9
[2] http://www.amwsites.com/blog/2011/03/get-rid-of-funky-escape-characters-from-git-diff/