|
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
|
[PLUG] What is my current shell?
|
All,
We have an oddball problem. Is there any portable way to determine
what shell you are using once you are inside a script?
Right now, we are thinking of using
which `echo $0`
As you can see here, $SHELL does not change when you switch shells.
[2:07pm] [shaha:pts/8] [shaha] : /gtc/staff/shaha/work/sortT > echo $SHELL
/usr/local/bin/tcsh
[2:08pm] [shaha:pts/8] [shaha] : /gtc/staff/shaha/work/sortT > bash
shaha@shaha:~/work/sortT$ echo $SHELL
/usr/local/bin/tcsh
This is for problems at customer sites where they are using the wrong
Bourne shell on Solaris (/bin/sh) when we want them to use
/usr/xpg4/bin/sh.
thanks,
Amul
___________________________________________________________________________
Philadelphia Linux Users Group -- http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion -- http://lists.phillylinux.org/mailman/listinfo/plug
|
|