mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-27 13:19:24 +01:00
Updated to use the new plugin ordering method.
This commit is contained in:
parent
0cd853ad35
commit
eb9bd70599
@ -87,8 +87,8 @@ conf.registerChannelValue(conf.supybot.plugins.Amazon, 'linkSnarfer',
|
||||
|
||||
class Amazon(callbacks.PrivmsgCommandAndRegexp):
|
||||
threaded = True
|
||||
callBefore = ['URL']
|
||||
regexps = ['amzSnarfer']
|
||||
|
||||
def callCommand(self, name, irc, msg, *L, **kwargs):
|
||||
try:
|
||||
super(Amazon, self).callCommand(name, irc, msg, *L, **kwargs)
|
||||
|
@ -118,6 +118,7 @@ def registerBugzilla(name, url='', description=''):
|
||||
class Bugzilla(callbacks.PrivmsgCommandAndRegexp):
|
||||
"""Show a link to a bug report with a brief description"""
|
||||
threaded = True
|
||||
callBefore = ['URL']
|
||||
regexps = ['bzSnarfer', 'bugzSnarf']
|
||||
|
||||
def __init__(self):
|
||||
|
@ -138,6 +138,8 @@ class Dunno(callbacks.Privmsg):
|
||||
messages with messages kept in a database, able to give more personable
|
||||
responses."""
|
||||
priority = 100
|
||||
callBefore = ['Misc']
|
||||
callAfter = ['MoobotFactoids']
|
||||
def __init__(self):
|
||||
callbacks.Privmsg.__init__(self)
|
||||
self.db = DunnoDB()
|
||||
|
@ -77,6 +77,7 @@ class Ebay(callbacks.PrivmsgCommandAndRegexp):
|
||||
get info about an auction.
|
||||
"""
|
||||
threaded = True
|
||||
callBefore = ['URL']
|
||||
regexps = ['ebaySnarfer']
|
||||
|
||||
_reopts = re.I | re.S
|
||||
|
@ -78,6 +78,7 @@ conf.registerChannelValue(conf.supybot.plugins.Gameknot, 'statSnarfer',
|
||||
|
||||
class Gameknot(callbacks.PrivmsgCommandAndRegexp):
|
||||
threaded = True
|
||||
callBefore = ['URL']
|
||||
regexps = ['gameknotSnarfer', 'gameknotStatsSnarfer']
|
||||
_gkrating = re.compile(r'<font color="#FFFF33">(\d+)</font>')
|
||||
_gkgames = re.compile(r's:</td><td class=sml>(\d+)</td></tr>')
|
||||
|
@ -74,6 +74,7 @@ conf.registerChannelValue(conf.supybot.plugins.Geekquote, 'geekSnarfer',
|
||||
|
||||
class Geekquote(callbacks.PrivmsgCommandAndRegexp):
|
||||
threaded = True
|
||||
callBefore = ['URL']
|
||||
regexps = ['geekSnarfer']
|
||||
|
||||
def callCommand(self, method, irc, msg, *L, **kwargs):
|
||||
|
@ -192,7 +192,8 @@ totalTime = conf.supybot.plugins.Google.state.time()
|
||||
|
||||
class Google(callbacks.PrivmsgCommandAndRegexp):
|
||||
threaded = True
|
||||
regexps = sets.Set(['googleSnarfer', 'googleGroups'])
|
||||
callBefore = ['URL']
|
||||
regexps = ['googleSnarfer', 'googleGroups']
|
||||
def __init__(self):
|
||||
callbacks.PrivmsgCommandAndRegexp.__init__(self)
|
||||
self.last24hours = structures.TimeoutQueue(86400)
|
||||
@ -390,7 +391,7 @@ class Google(callbacks.PrivmsgCommandAndRegexp):
|
||||
if not self.registryValue('groupsSnarfer', msg.args[0]):
|
||||
return
|
||||
queries = cgi.parse_qsl(match.group(1))
|
||||
queries = filter(lambda q: q[0] in ['threadm', 'selm'], queries)
|
||||
queries = [q for q in queries if q[0] in ('threadm', 'selm')]
|
||||
if not queries:
|
||||
return
|
||||
queries.append(('hl', 'en'))
|
||||
|
@ -310,7 +310,7 @@ def MoobotDB():
|
||||
return SqliteMoobotDB()
|
||||
|
||||
class MoobotFactoids(callbacks.PrivmsgCommandAndRegexp):
|
||||
priority = 98
|
||||
callBefore = ['Dunno']
|
||||
addressedRegexps = ['changeFactoid', 'augmentFactoid',
|
||||
'replaceFactoid', 'addFactoid']
|
||||
def __init__(self):
|
||||
|
@ -85,8 +85,9 @@ conf.registerChannelValue(conf.supybot.plugins.Python, 'aspnSnarfer',
|
||||
the recipe when it see an ASPN Python recipe link on the channel."""))
|
||||
|
||||
class Python(callbacks.PrivmsgCommandAndRegexp):
|
||||
modulechars = '%s%s%s' % (string.ascii_letters, string.digits, '_.')
|
||||
callBefore = ['URL']
|
||||
regexps = ['aspnRecipes']
|
||||
modulechars = string.ascii_letters + string.digits + '_.'
|
||||
def pydoc(self, irc, msg, args):
|
||||
"""<python function>
|
||||
|
||||
|
@ -105,6 +105,7 @@ class Sourceforge(callbacks.PrivmsgCommandAndRegexp):
|
||||
project's most recent bugs and rfes.
|
||||
"""
|
||||
threaded = True
|
||||
callBefore = ['URL']
|
||||
regexps = ['sfSnarfer']
|
||||
|
||||
_reopts = re.I
|
||||
|
Loading…
Reference in New Issue
Block a user