By Keith Mitnick on Sunday, 06 March 2016
Category: General

Add Color to the ls command in Mac OS X

Open Terminal and type:

nano .bash_profile

At the bottom of your .bash_profile, add these lines and save the file.

NOTE:  If you use a Dark terminal theme, use this:

export CLICOLOR=1
export LSCOLORS=GxFxCxDxBxegedabagaced


NOTE:  If you use a Light terminal theme, use this:

export CLICOLOR=1
export LSCOLORS=ExFxBxDxCxegedabagacad


Once your .bash_profile is saved, enter the command below:


ls -alh

The output should now be in different colors.

Leave Comments