Re: Global environment variables under Gnome?



> People,
> 
> A minor question just popped up recently: How do I set
> environment variables in Gnome? On my old setup (RH 6.2) it was
> just a question of adding the right export statements to /etc/profile,
> these somehow seemed to be inherited by my gnome session,
> however I recently switched to Debian 2.2 and it seems to handle
> this differently. I must specifically add a 'source /etc/profile' line to
> my user profile files, and it will only honor this from a terminal.
> This is a bit of a pain when installing things like Mozilla or Sun's
> JDK from tarballs, as these programs want several variables set
> before running.
> I already rewrote the Mozilla start script, however I don't want to
> this for every non-Debian package I install. Anybody got any
> clues?


In debian under /etc/X11/gdm/Sessions/Gnome
I find the following lines.

if [ -f /etc/environment ]; then
  . /etc/environment
fi

So you should be able to set everything in that file if you want to set it 
for all users.  You can also find these lines.

usrgnomerc=$HOME/.gnomerc
if [ -f $usrgnomerc ]; then
  . $usrgnomerc
fi

So you can set it in that file for user specific things.

/Erik - who hasn't tried any of that :)

-- 
Erik Bågfors               | Center for Parallel Computers
http://erik.bagfors.nu/    | http://www.pdc.kth.se/
erik bagfors nu            | bagfors pdc kth se  
Supporter of free software | GSM +46 70 398 54 43 
fingerprint: 6666 A85B 95D3 D26B 296B 6C60 4F32 2C0B 693D 6E32





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