Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have seen some examples on people getting colors in git output. I tried the following guide but unfortunately it didn't succeeded.

Is there anything else that needs to be done to get colored output? I'm using .oh-my-zsh together with regular Ubuntu and color works in the term.

Edit: I'm looking for colors like from this example (while doing a clone):

share|improve this question
up vote 15 down vote accepted

You can try this.

git config --global --add color.ui true

Or you can create a simple ~/.gitconfig to start with. something like.

    recentrepo = /Users/name/Workspace/repo/src/stable
    name = name
    email =
    whitespace = nowarn
    editor = vim
    diff = auto
    status = auto
    branch = auto
share|improve this answer
Thanks. As I wrote, I have tried this, but still no color. Well, no color is not exactly true. I get colored +'s and -'s while doing fast-forward. I'm looking for more colors like in the link I now posted. – grm May 24 '11 at 6:20
So this too does not work for you? That's strange. Which version, platform you are on. – CantGetANick May 24 '11 at 6:39
lol totally misunderstood your question. – CantGetANick May 25 '11 at 11:29

The example you posted is not supposed to be coloured; it is only because the blogging engine used by mistreats preformated text as code blocks, and highlights tokens as if it were program source.

For example, // is coloured differently because // marks the start of a comment in many programming languages, and in/var/done/using are reserved keywords.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .