dot desktop files: run as root (KDE/GNOME)
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi
This time I have a question ;)
I quite often package up apps that have to run as root (e.g. smart, aptitude, ...), including
console applications.
I almost always add a .desktop file to have it appear in the users' menu (even though it's a console
app).
Now, my question...
For KDE I found out somehow (it's not documented *anywhere*) that when you add the following two
lines to your .desktop file, it will prompt the user to enter the root password (using kdesu) and
then run as root:
X-KDE-SubstituteUID=true
X-KDE-Username=root
Is this the right way to do it ?
And what about GNOME ? Given the X-KDE- prefix, it only applies to KDE.
What tags do I have to add to a .desktop file to force an "su" (gnomesu, whatever) to the root user?
James, you should know that .. ? ;)
cheers
- --
-o) Pascal Bleser http://linux01.gwdg.de/~pbleser/
/\\
Is this the right way to do it ?
Seem to be Ref: /usr/share/applications/YaST.desktop
And what about GNOME ? Given the X-KDE- prefix, it only applies to KDE. What tags do I have to add to a .desktop file to force an "su" (gnomesu, whatever) to the root user? James, you should know that .. ? ;)
GNOME seems to respect those lines too, or at least for the YaST launcher, it prompts for root's p/w. -- James Ogley james@usr-local-bin.org Packages for SUSE: http://usr-local-bin.org/rpms Make Poverty History: http://makepovertyhistory.org
participants (2)
-
James Ogley
-
Pascal Bleser