Gary Fixler
Gary Fixler

Reputation: 6028

git log --decorate colors all the same

I've apt-get installed git version 1.7.0.4 on a fresh install of Ubuntu 10.04 on my new SSD. Everything works fine, except all log decorations - tags, local branches, remote branches, HEAD - are all always orange in a default bash terminal, as are the surrounding parentheses, all matching the SHA-1 hash value coloring. Nothing I do will change them. If I remove ui = auto from [color] in ~/.gitconfig then it all goes monochrome, but outside that, I can't get the default remote=red, local=green, HEAD=cyan, tag=yellow coloring that I had on the old Ubuntu 10.04 install I've just moved from.

There are no other color things in ~/.gitconfig (it's very default/vanilla, and even stripping it all out doesn't fix it), and there's nothing related to colors in myrepo/.git/config. This happens in all repos.

Do I have a bad install? Is it a terminal issue? I've fiddled with everything related to fonts, colors, backgrounds, etc, in the terminal profile properties to no avail. I've tried everything I can find related to colors online and on stackoverflow... no luck. Colors do seem to work in diffs, i.e. this does change the meta info for each file in a diff:

[color "diff"]
    meta = magenta

Upvotes: 1

Views: 1156

Answers (1)

valk
valk

Reputation: 9874

Just found this answer, the one-liner worked for me. And, I'm on Ubuntu 12.04.

git config --global color.ui auto

Upvotes: 1

Related Questions