Change terminal colors (TTY) in bashrc

To change your directory colors, open up your ~/.bashrc file with your editor

nano ~/.bashrc

and make the following entry at the end of the file:

LS_COLORS=$LS_COLORS:'di=0;35:' ; export LS_COLORS

Some nice color choices (in this case 0;35 it is purple) are:

The first number is the style (1=bold), followed by a semicolon, and then the actual number of the color, possible styles are:

All possible colors:

These can even be combined, so that a parameter like:


in your LS_COLORS variable would make directories appear in bold underlined red text with a green background!

You can also change other kinds of files when using the ls command by defining each kind with:

*.rpm = files with the ending .rpm

After changing the bashrc file, you can activate your changes by entering:

source ~\.bashrc
Last update: Thu, 03 Jan 2019 17:53:40