summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Napora <napcok@gmail.com>2016-01-22 11:11:42 +0100
committerDaniel Napora <napcok@gmail.com>2016-01-22 11:11:42 +0100
commit7b6d0b785b652b202a629a691cf13475cf3e8501 (patch)
tree52524a5c172ab01175999710e2f6d97457e9d498
parent6f90bd0519f6e3028a4f69f42ba7168fe7575cea (diff)
downloadmageiawelcome-7b6d0b785b652b202a629a691cf13475cf3e8501.tar
mageiawelcome-7b6d0b785b652b202a629a691cf13475cf3e8501.tar.gz
mageiawelcome-7b6d0b785b652b202a629a691cf13475cf3e8501.tar.bz2
mageiawelcome-7b6d0b785b652b202a629a691cf13475cf3e8501.tar.xz
mageiawelcome-7b6d0b785b652b202a629a691cf13475cf3e8501.zip
use xdg-open for irc (mga#17277)
-rw-r--r--usr/share/mageiawelcome/helpers.py8
-rw-r--r--usr/share/mageiawelcome/index.html2
-rw-r--r--usr/share/mageiawelcome/mageiawelcome.py10
3 files changed, 3 insertions, 17 deletions
diff --git a/usr/share/mageiawelcome/helpers.py b/usr/share/mageiawelcome/helpers.py
index 080eb5e..ea581f3 100644
--- a/usr/share/mageiawelcome/helpers.py
+++ b/usr/share/mageiawelcome/helpers.py
@@ -34,14 +34,6 @@ def get_desktop_name2(x):
'X-Cinnamon':'Cinnamon',
}.get(x,'unknown')
-def get_irc_client():
- if os.path.exists("/usr/bin/hexchat"): irc_client = "/usr/bin/hexchat &"
- elif os.path.exists("/usr/bin/xchat-gnome"): irc_client = "/usr/bin/xchat-gnome &"
- elif os.path.exists("/usr/bin/xchat"): irc_client = "/usr/bin/xchat &"
- elif os.path.exists("/usr/bin/konversation"): irc_client = "/usr/bin/konversation &"
- elif os.path.exists("/usr/bin/quassel"): irc_client = "/usr/bin/quassel &"
- else: irc_client = "none"
- return irc_client
def is_installed(name):
return os.WEXITSTATUS(os.system('rpm -q --quiet ' + name))
diff --git a/usr/share/mageiawelcome/index.html b/usr/share/mageiawelcome/index.html
index 188ff33..512c6e3 100644
--- a/usr/share/mageiawelcome/index.html
+++ b/usr/share/mageiawelcome/index.html
@@ -181,7 +181,7 @@ PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
<h5>$h_support</h5>
<a href="https://forums.mageia.org/en/" class="weblink button medium"><i class="icon-heart"> </i> $forum</a><br />
<a href="https://wiki.mageia.org/en/Category:Documentation" class="weblink button medium"><i class="icon-globe"> </i> $wiki</a><br />
- <a href="irc" class="weblink button medium"><i class="icon-comments"> </i> $chat</a><br />
+ <a href="irc://irc.freenode.net/#mageia" class="weblink button medium"><i class="icon-comments"> </i> $chat</a><br />
<a href="https://bugs.mageia.org/" class="weblink button medium"><i class="icon-ambulance"> </i> $bugs</a><br />
</div>
<div class="mgalinks col_4">
diff --git a/usr/share/mageiawelcome/mageiawelcome.py b/usr/share/mageiawelcome/mageiawelcome.py
index f2660aa..a207e70 100644
--- a/usr/share/mageiawelcome/mageiawelcome.py
+++ b/usr/share/mageiawelcome/mageiawelcome.py
@@ -187,14 +187,8 @@ def main():
os.system("touch " + home + "/.mageiawelcome/norun.flag")
elif msg.startswith("http"):
os.system("xdg-open " + msg)
- elif msg == "irc":
- irc_client = get_irc_client()
- if irc_client == "none":
- if desktop == "KDE":
- subprocess.Popen("gurpmi konversation", shell=True)
- else:
- subprocess.Popen("gurpmi hexchat", shell=True)
- else: os.system(irc_client)
+ elif msg.startswith("irc"):
+ os.system("xdg-open " + msg)
elif msg.startswith("run"):
args = shlex.split(msg)
args.pop(0)