summaryrefslogtreecommitdiffstats
path: root/usr/share
diff options
context:
space:
mode:
authorPapoteur <papoteur@mageia.org>2017-08-12 10:23:36 +0200
committerPapoteur <papoteur@mageia.org>2017-08-12 10:23:36 +0200
commit4c2474ddc50674e1e08bc0d798e71cf39e4834f0 (patch)
tree8e8594d680b125edf4987378ec3fd74dfebbeb08 /usr/share
parent096701893d70a9e75cb9839ad37ad50a55f68f2f (diff)
downloadmageiawelcome-4c2474ddc50674e1e08bc0d798e71cf39e4834f0.tar
mageiawelcome-4c2474ddc50674e1e08bc0d798e71cf39e4834f0.tar.gz
mageiawelcome-4c2474ddc50674e1e08bc0d798e71cf39e4834f0.tar.bz2
mageiawelcome-4c2474ddc50674e1e08bc0d798e71cf39e4834f0.tar.xz
mageiawelcome-4c2474ddc50674e1e08bc0d798e71cf39e4834f0.zip
better management of DESKTOP_SESSION (mga#21454)
use XDG_CURRENT_DESKTOP instead of reporting "unknown"
Diffstat (limited to 'usr/share')
-rw-r--r--usr/share/mageiawelcome/mageiawelcome.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/usr/share/mageiawelcome/mageiawelcome.py b/usr/share/mageiawelcome/mageiawelcome.py
index 5f14890..cbad80a 100644
--- a/usr/share/mageiawelcome/mageiawelcome.py
+++ b/usr/share/mageiawelcome/mageiawelcome.py
@@ -50,14 +50,15 @@ def main():
arch = '32-bit'
home = os.getenv("HOME")
username = os.getenv("USER")
- if os.getenv("DESKTOP_SESSION") != "" :
+ try:
desktop = get_desktop_name(os.path.basename(os.getenv("DESKTOP_SESSION")))
- else:
+ except:
desktop = 'Other'
if desktop == 'Other':
desktop = get_desktop_name2(os.getenv("XDG_CURRENT_DESKTOP"))
-
+ if desktop == 'unknown':
+ desktop = os.getenv("XDG_CURRENT_DESKTOP")
#collect packages nad its status
listapp = get_listapp()