Shell Aliases & .kshrc

From: Andrew Garnett (andrewwdg@YAHOO.CO.UK)
Date: Tue Feb 11 2003 - 10:31:36 EST


All,
I have a .kshrc file set up to create aliases. All
works fine. When I log in to <user> they're all there,
including one called startup.
If I run su - <user> "-c startup" it says it doesn't
exist. If I therefore run su - <user> "-c alias" none
of the aliases are displayed.

If I put some debugging messages in .kshrc I can see
that when I call the above commands, .kshrc DOES get
obeyed, and when I put an "alias" command at the end
of .kshrc, the aliases ARE there.
So it appears that the "su - user" command is logging
in and running kshrc correctly, but the submitted
command doesn't see the aliases.
I've even tried dotting the .kshrc, but it can't be
seen.

Can anyone explain, or suggest how to run an alias
with su
Thanks,
      A

__________________________________________________
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com



This archive was generated by hypermail 2.1.7 : Wed Apr 09 2008 - 22:16:35 EDT