Bug 36905 - Improve LXDE detection for xdg-open
Summary: Improve LXDE detection for xdg-open
Status: RESOLVED FIXED
Alias: None
Product: Portland
Classification: Unclassified
Component: xdg-utils (show other bugs)
Version: 1.1.0 rc1
Hardware: Other All
: medium normal
Assignee: Portland Bugs
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-05-06 04:49 UTC by snafu
Modified: 2012-03-02 10:53 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments

Description snafu 2011-05-06 04:49:59 UTC
As reported in bug #36126 as a side note, xdg-open is not able to detect a running LXDE session on my system (Linux Mint). I now stumbled over https://bugs.launchpad.net/ubuntu/+source/hardinfo/+bug/778148, where the same problem was reported for Lubuntu. According to the comments there, it seems to be a good (i.e. robust) idea to look inside the environment variable $XDG_CURRENT_DESKTOP instead of $DESKTOP_SESSION. You perhaps want to change this just for the upcoming release in order to satisfy the growing LXDE user base. :-)
Comment 1 Rex Dieter 2011-05-06 04:53:48 UTC
Perhaps, though I'm curious where XDG_CURRENT_DESKTOP comes from.  Is this part of some standard or spec?
Comment 2 snafu 2011-05-06 05:45:37 UTC
Concerning where $XDG_CURRENT_DESKTOP comes from, it seems that there is at least some kind of request to add this to the spec (see discussion: http://lists.freedesktop.org/archives/xdg/2011-March/011847.html). As stated there, the LXDE project is already using that variable. I also found a changelog entry for the lxpanel package on https://launchpad.net/ubuntu/+source/lxpanel/0.5.4.1-1, which mentions the use of this variable. So even if it is not "official", it can IMHO be assumed, that LXDE is not going to change its behaviour in the near future.
Comment 3 Rex Dieter 2011-05-06 06:05:06 UTC
well, I usually would be hesitant (and since it's lxde and other's changing stuff that breaks things here), but in this case I actually do like the intent of XDG_CURRENT_DESKTOP, so ok.
Comment 4 snafu 2011-10-22 02:29:12 UTC
Is there any chance that this is getting done? :-)

What about looking into $DESKTOP_SESSION first, and in case that there is nothing in it, which xdg-open is able to handle, one would fallback to $XDG_CURRENT_DESKTOP. This should not arise any negative consequences at all.

BTW: I installed the official Lubuntu release and like Linux Mint it puts its own value ("Lubuntu") into $DESKTOP_SESSION. Though, DE-detection is broken here, too (and perhaps on many other systems either).

I really would appreciate you to implement that functionality.
Comment 5 Rex Dieter 2012-03-02 10:53:14 UTC
So, I think this is largely implemented in
http://cgit.freedesktop.org/xdg/xdg-utils/commit/?id=3ba869a97b737fd308502a7f9e63bda202891642

for completeness, see current
detectDE function in:
http://cgit.freedesktop.org/xdg/xdg-utils/tree/scripts/xdg-utils-common.in


feel free to re-open or open a new bug if you find any specific failings.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.