Re: global environment variables?
On Sun, Dec 02, 2001 at 04:30:11PM -0800, Craig Dickson wrote:
| dman wrote:
| > What Nemo and I are looking for is a way to set the environment for
| > apps run via the panel (that don't have a login shell).
| What process starts the panel?
| Isn't there a login shell somewhere at the root of all the processes
| that get started for you at login time? I
| would think if you could set a variable in that shell, and export it,
| then it should still be visible to processes launched by the panel.
You would think so, but it doesn't work that way. I made ~/.xsession
look like :
echo "`date`" >> ~/Log
echo "$LANG" >> ~/Log
echo >> ~/Log
In ~/Log $LANG was shown to properly be en_US.UTF-8, however processes
(eg gvim) launched from gnome-panel had the system default of en_US
(or was it "C"?, same difference).
| Having poked around the system a bit for similar purposes, I find the
| following files to be useful in getting environment variables visible
| more or less globally:
I could try /etc/environment for myself, but I don't think it will
work. Also I wanted to do this for just my user and let others stick
with the default $LANG.
| Presumably there are equivalent files available for other login
| I don't know offhand how you could make a variable visible to all cron
| jobs globally. There is a basic problem there, that each user has his
| own crontab file, and can set or override variables as he pleases.
This is a problem? ;-). I like it when users can do their own thing,
especially when I am a user on a sytem (without root access).
If your life is a hard drive,
Christ can be your backup.