Re: ls --color
- From: "Jonathan A." <invalid@xxxxxxxxxxx>
- Date: Sun, 05 Feb 2006 17:48:59 GMT
On Sun, 5 Feb 2006 15:38:16 +0000, chris-usenet@xxxxxxxxxxxx
<chris-usenet@xxxxxxxxxxxx> appears to have said:
Fraser Sinclair <dummy@xxxxxxxxxxxxx> wrote:
dircolors just forms LS_COLORS.
Exactly.
Don't forget LS_OPTIONS.
"ls" colors executables even if they
are not in LS_COLORS
No it doesn't.
It will if $LS_OPTIONS has "--color=auto" or "--color=always" set.
(a) Your "ls" will have been aliased to "ls --colors" to even add
the colours in the first place.
In my case, it's aliased to "/bin/ls $LS_OPTIONS", and LS_OPTIONS is
set to "--color=auto -F -b -T 0". If you really want to see what ls
will output with *no* interference from dircolors, just type "/bin/ls"
instead of the aliased "ls".
(b) Re-read the documentation for "dircolors"
If the /etc/DIR_COLORS file is as well commented as the one on my
Slackware box, (I guess it's the stock file from the GNU coreutils
distribution) it's an informative read, as well.
Back at the top of the thread, Fraser Sinclair wrote:
The colors are useful but not yet on samba connections to windows
boxes because they need to be mounted +x to run cmd files.
You mount the shares with perms that allow execute permission for all
files? Sounds dangerous to me.
all the files listed with ls to be colored with the exe color.
Removing this color from LS_COLORS does no good because if a file has
execute permission the file extension colors are ignored.
I *think* the reason you can't change it by removing the EXEC color from
/etc/DIR_COLORS is that the default is compiled into /bin/ls. Anyhow...
if you really want to unset the color for executable files, just set
EXEC to "00" in DIR_COLORS. I'd be looking for a better way to manage
exec perms through mount/samba options, or something, though.
cya,
Jonathan
--
Don't just hit reply. Email address is broken. Thank
your friendly neighborhood spammer. Email replies to:
user: daboid domain: cox<dot>net
.
- Follow-Ups:
- Re: ls --color
- From: Fraser Sinclair
- Re: ls --color
- References:
- ls --color
- From: Fraser Sinclair
- Re: ls --color
- From: chris-usenet
- Re: ls --color
- From: Fraser Sinclair
- Re: ls --color
- From: chris-usenet
- ls --color
- Prev by Date: Re: ls --color
- Next by Date: Re: Hacked....
- Previous by thread: Re: ls --color
- Next by thread: Re: ls --color
- Index(es):
Relevant Pages
|