On Sunday, January 5, 2003, at 11:19 PM, Michael Wardle wrote:

Hi Adam

When you perform an "su", be sure to add the "-l" or "-" option. This
will cause "su" to log you in as root, which causes your shell (bash) to
read /etc/bashrc, which in turn sources the script files in
/etc/profile.d. If you do not add the "-l" option, "su" simply changes
your user to root without doing most of the normal initialization.
I always do; my mistake for not explicitly specifying this.  :)

Doing this will run colorls.sh in a subshell, so all changes to the
shell's environment will be lost when the script exits. If you manually
want to run colorls.sh, try sourcing it like so:
# . /etc/profile.d/colorls.sh
or
# source /etc/profile.d/colorls.sh
I realize this problem, but in order to get the debug output I had to run it under a -x shell. BTW, a "source" or a "." of the colorls.sh file also does not gather in the "ll" or "l." aliases. I should have pointed out that the aliases for "cp", "mv", "rm", and "vi" ARE imported.

ahp

Attachment: PGP.sig
Description: PGP signature

Reply via email to