diff options
Diffstat (limited to 'ircbot/rssbot.py')
-rwxr-xr-x | ircbot/rssbot.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ircbot/rssbot.py b/ircbot/rssbot.py index f0e19c5a..cb7a1543 100755 --- a/ircbot/rssbot.py +++ b/ircbot/rssbot.py @@ -9,7 +9,7 @@ from datetime import datetime from time import sleep class RssBot(irc.bot.SingleServerIRCBot): - def __init__(self, rss, name, server='ire', port=6667, chan='#news', timeout=60): + def __init__(self, rss, name, url_shortener="http://localhost", server='ire', port=6667, chan='#news', timeout=60): irc.bot.SingleServerIRCBot.__init__(self, [(server, port)], name, name) self.url = rss self.name = name @@ -47,7 +47,7 @@ class RssBot(irc.bot.SingleServerIRCBot): #try: # self.send(entry.title + " " + entry.link + " com: " + entry.comments) #except AttributeError: - shorturl = subprocess.check_output(["curl", "-sS", "-F", "uri=" + entry.link, "http://wall:1337"]).decode() + shorturl = subprocess.check_output(["curl", "-sS", "-F", "uri=" + entry.link, url_shortener]).decode() self.send(entry.title + " " + shorturl) self.oldnews.append(entry.link) self.lastnew = datetime.now() |