Bash, in Color

Tip of the Trade: A little color on the command line makes things easier to
read.

I find that a little color on the command line helps make things easier to
read. ls is easy to colorize: just add the line:

alias ls='ls --color=auto'

in your ~/.bashrc (then source it or open another terminal).

You can also set color up for your manpages. The easiest way to do this
is using most as a pager: Install the most package, and
then type

export MANPAGER="/usr/bin/most -s"

Try looking at a man page and you'll suddenly see it in color! However,
most isn't as good as less as a pager, and if
you're accustomed to less you don't necessarily want to retrain your
fingers to new commands. An alternative is to set up assorted termcap-related
environment variables to provide colors. Add these lines to your
.bashrc:

(with thanks to the
CLUG wiki, which also has some other tips). Source your
~/.bashrc and type export MANPAGER="less" to clear the
most setting (or just open a new terminal window) and take a look at
a man page.

Note: not all systems automatically source ~/.bashrc on login. If
you're having problems, trying manually sourcing ~/.bashrc, and if
that works, add a line

source ~/.bashrc

to your ~/.bash_profile.

Finally, you can install the package grc to provide color for
certain commands (check /etc/grc.conf to confirm which ones -- you
can also add your own definitions here). Use it like this:

grc diff file1 file2

Although in the case of diff, a better solution may be to use
vimdiff or gvimdiff, both of which provide colors by
default and also puts the files side-by-side in a much easier to read
format.