ksh - how do you keep aliases permanent?

4197,ATTT rbr at bonnie.ATT.COM
Mon Mar 11 23:56:01 AEST 1991


In article <544 at genco.bungi.com> rad at genco.bungi.com (Bob Daniel) writes:
>When defining aliases, is there a way to keep them permanent as they are defined
>rather than inserting them directly into .profile?  If I have to, I'll write
>something that makes aliases and stores them in a file that is launched by
>.profile at login but would like to know if it can be done before spending 
>time on that routine.

Store them in a file named ".kshrc" which will be read by ksh at login. At
least this is true "ksh" on AT&T UNIX V.  Other implementations may use a
different name for the file. Check your Ksh manual or talk to your system
administrator.

The following is an example showing a few lines from my ".kshrc".  You can
put them in one per line "alias <name> = 'command line' or bunch them as
I have.

alias   \
        lf='ls -CF'                \
        ll='ls -l'                 

Bob Rager



More information about the Comp.unix.shell mailing list