LS_COLORS

Tom H tomh0665 at gmail.com
Fri Jan 30 12:06:51 UTC 2015


On Thu, Jan 29, 2015 at 2:46 PM, Linda <haniganwork at earthlink.net> wrote:
>
> Thanks I had found some of these but didn't know about the man page. I am
> still not finding a place where the global defaults are set maybe they are
> written into the code. I guess I'll have to settle for making the changes
> in .bashrc for each user.

>From "man dircolors": "a precompiled database is used".

If the users haven't been created yet, you can change "/etc/skel/.bashrc".

However, if you just want to change the colors, you could create
"~/.dircolors" (and "/etc/skel/.dircolors") and the default
"~/.bashrc" will pick it up.

If you want to set the same colors for all users, you could create an
"/etc/dircolors" (or "/etc/dir_colors" or "/etc/DIRCOLORS" or
"/etc/DIR_COLORS" or ...) and use eval "$(dircolors -b <file>)" to
load it from "/etc/bash.bashrc". I'm surprised that Ubuntu doesn't do
that by default. For example, Gentoo's default "/etc/bash/bashrc"
loads "/etc/DIR_COLORS" if it exists.




More information about the ubuntu-users mailing list