Re: Absolute paths to applications in .desktop files



Hi,

Le mercredi 09 juillet 2008, à 23:28 +0200, Josselin Mouette a écrit :
> Hi,
> 
> the topic was raised on debian-devel and I think we should make sure
> that we are not missing anything before someone starts a crusade about
> it, so I prefer asking here.
> 
> Currently, none of the .desktop files shipped in GNOME modules specify
> an absolute path for the executable. However this is desirable for the
> following reasons (shamelessly quoting Vincent Lefevre, as I don’t have
> much to add):
> 
>      1. Each .desktop file is a file associated with /usr/bin/something,
>         which is distributed in the same package.
>      2. Taking the user's $PATH into account may have unexpected
>         effects,   such as running a different version of the program
>         which may accept a different set of MIME types, or worse,
>         running another program installed it the user’s $HOME/bin
>         directory.
>      3. In config files, $PATH is generally used when one doesn't know
>         the location of the program, for flexibility, but this is not
>         the case here (see point 1).
> 
> Currently, in Debian, we hardcode the path specifically for gnome-games
> – as executables are in /usr/games and some stupid users remove it from
> their PATH – but not for the rest, and given the reasons above, I don’t
> understand why they are not directly hardcoded upstream.
> 
> Am I missing something or is it just about not having too
> many .desktop.in.in files?

This is more complex than that. If I copy a launcher from the
applications menu to my panel or desktop and then run my session in
jhbuild, I might want to use the jhbuilt application instead of the
system application.

If the user changes $PATH, then it has to be expected that some things
might break. Also, if the user has gcalctool in $HOME/bin, he'll run
into weird things when typing gcalctool in the run dialog, eg.

So I'm not sure this is worth it.

Vincent

-- 
Les gens heureux ne sont pas pressés.


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