Bug 244269

Summary: KDE should read ~/.profile at the same time as ~/.kde/env/*.sh
Product: [Unmaintained] ksmserver Reporter: Ryan Thompson <rct+bugs>
Component: generalAssignee: Lubos Lunak <l.lunak>
Status: RESOLVED WORKSFORME    
Severity: wishlist    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Ubuntu   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Ryan Thompson 2010-07-12 04:46:07 UTC
Version:           unspecified (using Devel) 
OS:                Linux

Users can use ~/.profile to set environment variables for their session. GNOME will source this file, and any changes that it makes to the environment apply to the entire GNOME session. For KDE, the equivalent feature is to put scripts in ~/.kde/env/ ending in ".sh". It would be nice if KDE also read ~/.profile.

In other words, I would like KDE to act as if the following command were executed:
$ ln -sh ~/.profile ~/.kde/env/profile.sh

Reproducible: Didn't try




This caused some problems for me when I was trying to run some of my scripts in ~/bin/ using Krunner, which didn't have my custom $PATH.
Comment 1 Oswald Buddenhagen 2010-07-12 17:17:15 UTC
the Xsession script supplied with kdm does just that, and it's the right place to do it - everything else would be just wrong.
if your distribution's Xsession script does something different ... oh, well - tough luck.
Comment 2 Ryan Thompson 2010-07-12 22:51:10 UTC
Thanks for pointing me to that script. I looked there, and I realized that if my $SHELL is set to zsh, then it sources ~/.zprofile instead of ~/.profile. I guess GNOME just always does ~/.profile. So my fix is this:

$ ln -s .profile ~/.zprofile

Since my .profile works for either shell.

Thanks!