Bug 185528 - autosters systemsetting's module does not start pre-KDE scripts
Summary: autosters systemsetting's module does not start pre-KDE scripts
Status: RESOLVED NOT A BUG
Alias: None
Product: systemsettings
Classification: Applications
Component: kcm_autostart (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Laurent Montel
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-02-25 14:34 UTC by Salvatore Brigaglia
Modified: 2012-11-09 15:34 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Salvatore Brigaglia 2009-02-25 14:34:22 UTC
Version:            (using Devel)
OS:                Linux
Installed from:    Compiled sources

The systemsetting's autostart module give the possibility to add pre-KDE scripts. This should load a script whyle kdm is shown, and before you enter your kde desktop.
While adding a binary or a .desktop file in the first section works, the script section does not launch the configured scripts.
Comment 1 Jekyll Wu 2012-11-09 15:34:47 UTC
"pre-KDE startup" scripts  are put under ~/.kde/env. As the folder name implies, those scripts are used to setup the environment for the whole KDE session, so they are "sourced", not "executed".

Here is the relevant part in startkde.


# Source scripts found in <localprefix>/env/*.sh and <prefixes>/env/*.sh
# (where <localprefix> is $KDEHOME or ~/.kde, and <prefixes> is where KDE is installed)
#
# This is where you can define environment variables that will be available to
# all KDE programs, so this is where you can run agents using e.g. eval `ssh-agent`
# or eval `gpg-agent --daemon`.
# Note: if you do that, you should also put "ssh-agent -k" as a shutdown script
#
# (see end of this file).
# For anything else (that doesn't set env vars, or that needs a window manager),
# better use the Autostart folder.

libpath=`kde4-config --path lib | tr : '\n'`

for prefix in `echo "$libpath" | sed -n -e 's,/lib[^/]*/,/env/,p'`; do
  for file in "$prefix"*.sh; do
    test -r "$file" && . "$file"
  done
done