Login shell?

Leo de Wit leo at philmds.UUCP
Sun Oct 23 18:01:08 AEST 1988


In article <7677 at boring.cwi.nl> dik at cwi.nl (Dik T. Winter) writes:
|In article <842 at philmds.UUCP> leo at philmds.UUCP (Leo de Wit) writes:
| > 2) When I exec a shell in my .profile file (for instance if I want my
| > own shell instead of /bin/sh or /bin/csh and don't want to bother my
| > system manager), this shell doesn't start with '-'.
|
|But why not?  This is just what I have done for a long time: in my bin:
|	ln -s $HOME/bin/my_shell -my_shell
|and at the start of my .profile:
|	case $SHELL in
|	*my_shell)	;;
|	*)	SHELL=$HOME/bin/my_shell
|		PATH=$HOME/bin exec -my_shell
|	esac
|Works like a charm.  My shell will even do .profile.

I used that trick myself; not from a .profile but to get a .profile read.
But as far as I know, symbolic links are a BSD feature; when you have to
use a hard link, it may not be possible (different filesystem); even cp
fails if the original shell wasn't readable.

                                             Leo.



More information about the Comp.unix.questions mailing list