View Full Version : Shell game

4th April 2006, 04:42 PM
My login shell on a particular machine is bash. If I invoke a tcsh shell, the environmental variable SHELL does not get set to tcsh. What's up with that?

[me@machine ~]# echo $SHELL
[me@machine ~]# tcsh
[me@machine ~]# echo $SHELL
[me@machine ~]# env|fgrep sh
LS_COLORS=no=00:fi=00:di=00;34:ln=00;36:pi=40;33:s o=00;35:bd=40;33;01:cd=40;33;01:or=01;05;37;41:mi= 01;05;37;41:ex=00;32:*.cmd=00;32:*.exe=00;32:*.com =00;32:*.btm=00;32:*.bat=00;32:*.sh=00;32:*.csh=00 ;32:*.tar=00;31:*.tgz=00;31:*.arj=00;31:*.taz=00;3 1:*.lzh=00;31:*.zip=00;31:*.z=00;31:*.Z=00;31:*.gz =00;31:*.bz2=00;31:*.bz=00;31:*.tz=00;31:*.rpm=00; 31:*.cpio=00;31:*.jpg=00;35:*.gif=00;35:*.bmp=00;3 5:*.xbm=00;35:*.xpm=00;35:*.png=00;35:*.tif=00;35:
LESSOPEN=|/usr/bin/lesspipe.sh %s

And what's that underscore in the environment about?

This is on FC4 with kernel 2.6.12-1.1447_FC4

Conversely, on an FC4 account where the login shell is tcsh, and I invoke a bash shell, the SHELL environmental variable is not set to bash.