[Bryen]
On Wed, 2007-10-17 at 19:43 -0400, François Pinard wrote:
[Bryen]
>Is there a way to disable color coding in the 'ls' command permanently?
Short of modifying and recompiling the code (from GNU coreutils), you
might add something like this (untested) in your ~/.bashrc file:
ls() { /bin/ls --color=none "$@"; }
and then, you should not get colors when working interactively.
I tried that line and it didn't work, tried it in various tinkerings and
it still didn't work. Then again, you did say "untested." :-)
Hello, Bryen. A bit teased by your remark :-), I tried it here, and it
works for me. However, Ti Kan (in this thread) probably put the finger
on the real problem, which is that "ls" has to be unaliased first.
Long ago, when SuSE was still a small shop, I asked for all aliases to
be turned into shell functions in the distributed SuSE, and they did so
in the release which followed. But, a few releases later, the aliases
returned, and I did not insist for them to disappear again. But on my
side, I unalias everything at the start of my .bashrc file, and did it
for so long that I forgot about it, sorry!
The reason I dislike aliases is that they sometimes get the bash syntax
analyzer to misbehave in unexpected ways, while shell functions are much
more regular and predictable in that respect. I did not use aliases in
years, and surely spared myself trouble by sticking to my decision :-).
--
François Pinard http://pinard.progiciels-bpi.ca
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]