[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Login Shell/Profile: Stop the Madness



Michael wrote:
> After much consternation I feel the need to vent about shell
> environment initialization. With the default Debian installation,
> /etc/profile and~/.bash_profile are not sourced in the X windows
> environment. Apparently this is because at no time is a login shell
> created which is necessary to trigger profile initialization.

Although it's annoying that this is the way *dm work it is the only
sensible way to do it (at least that I've heard!)

Think of this: The display manager is in essence a series of shell
scripts with a fancy front-end. Now each of these shell scripts must use
a certain shell (bash, sh, csh, tcsh, ksh, zsh, the list goes on) and
each user on the system could potentially be using a different shell.

Now do you have the display manager source every possible file that
should be sourced for each possible shell? Only source the files that
should be sourced for the shell that the login manager uses? Or do you
setup a system where by the users shell is determined and the
appropriate files sourced?

I hope if you think about it you'll realise that it is highly
non-trivial to implement a system where no matter which shell the user
uses the dm will act in the same way.

For instance if the dm uses a bash login shell and I have two users on
the system one using tcsh and one using bash. Then the bash user would
have his login files sourced and the tcsh user would not

-- 
OoberMick
(Role-playing with Mensa)

CBG:	Verily I declare that the Earth revolves around the
	Sun and not t'other way round.

Lyndsey Nagle:
	Stop looking down my blouse Copernicus.

CBG:	Forsooth, mine eyes doth rove of their own accord.

		They Saved Lisa's Brain (Episode AABF18)

Attachment: pgpkxU123n2Th.pgp
Description: PGP signature


Reply to: