OSX Terminal Colors Suddenly Gone – LSCOLORS CLICOLOR

If for whatever reason your ls command is no longer showing colored directories and looks like so:

Check the output of echo $TERM

$>echo $TERM
xterm-256color

It should be xterm-color

Mine was xterm-256color — probably set when my graphics card bugged out.

Edit your terminal config file (mine is bash, so ~/.bash_profile or ~/.bashrc) and add export TERM=xterm-color somewhere (or just enter into your bash shell for temporary results).

$>export TERM=xterm-color

After setting TERM to xterm-color, my directories look like they used to:

2 thoughts on “OSX Terminal Colors Suddenly Gone – LSCOLORS CLICOLOR

  1. Brilliant! This had been bothering me for some time and I’d nearly given up on it. Now colour is back in my life – thanks so much for the tip.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s