Nicolas Bouliane

Add some color to the OSX Terminal

Posted on

If you find the OS X Terminal’s lack of color hard on the eyes, here’s how to set the colours.

Open ~/.bash_profile and add this:

export CLICOLOR=1
export LSCOLORS=GxFxCxDxBxegedabagaced
export PS1="[\033[36m]\u[\033[m][\033[32m]:[\033[33;1m]\W[\033[m]\$ "
alias ls='ls -GFh'

The first line enables colours, the second sets the colors for ls and the last one sets the terminal’s color scheme. Finally, the last line enables color by default on the ls command.

You will find a more detailed description of the colour scheme syntax here.