I have just installed XCode and GitHub for Mac. I have successfully run "GitHub->Install Command Line Utility". I can connect to repositories with both apps and I can use the git command in the terminal.

However the git command does not use any colors (as I am used to just like in the below screenshot).

What can I do to get colors (preferably directly in OSX termianl, but an extra console would do too).

git in colored console

link|improve this question

69% accept rate
feedback

1 Answer

up vote 0 down vote accepted
git config --global color.branch auto
git config --global color.diff auto
git config --global color.status auto
git config --global color.ui auto

The global configuration is saved to ~/.gitconfig, which you can also edit directly with a text editor.

Refer to the manual of git-config for more options.

link|improve this answer
Strange, on Windows I did not have to do this. – bitbonk Sep 11 '11 at 13:24
@bitbonk: The msysGit package comes with a system-wide configuration file which enables colors automatically. – grawity Sep 11 '11 at 14:02
How can I find out where I got git from? I guess it can only be the GitHub app or XCode – bitbonk Sep 11 '11 at 23:42
@bitbonk: GitHub probably bundles git with their app. Certainly not XCode. – grawity Sep 12 '11 at 7:17
1  
XCode 4 supports git natively: developer.apple.com/technologies/tools/… – bitbonk Sep 12 '11 at 9:35
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.