Various: Fix output redirection.
* Encyclopedia * PackageInfo
This commit is contained in:
parent
9cb39012f8
commit
ed35f240fd
|
@ -24,7 +24,7 @@ import supybot
|
||||||
import supybot.world as world
|
import supybot.world as world
|
||||||
from imp import reload
|
from imp import reload
|
||||||
|
|
||||||
__version__ = "2.9"
|
__version__ = "3.0"
|
||||||
__author__ = supybot.Author("Krytarik Raido", "krytarik", "krytarik@tuxgarage.com")
|
__author__ = supybot.Author("Krytarik Raido", "krytarik", "krytarik@tuxgarage.com")
|
||||||
__contributors__ = {
|
__contributors__ = {
|
||||||
supybot.Author("Dennis Kaarsemaker", "Seveas", "dennis@kaarsemaker.net"): ['Original Author'],
|
supybot.Author("Dennis Kaarsemaker", "Seveas", "dennis@kaarsemaker.net"): ['Original Author'],
|
||||||
|
|
|
@ -86,7 +86,7 @@ msgcache = {}
|
||||||
def queue(irc, target, msg):
|
def queue(irc, target, msg):
|
||||||
if world.testing:
|
if world.testing:
|
||||||
# don't mess up testcases
|
# don't mess up testcases
|
||||||
irc.reply(msg, to=target)
|
irc.reply(msg, to=target, private=True)
|
||||||
return
|
return
|
||||||
now = time.time()
|
now = time.time()
|
||||||
for m in list(msgcache.keys()):
|
for m in list(msgcache.keys()):
|
||||||
|
@ -101,7 +101,7 @@ def queue(irc, target, msg):
|
||||||
msg = msg[:-len(oldmsg)] + 'Please see above'
|
msg = msg[:-len(oldmsg)] + 'Please see above'
|
||||||
else:
|
else:
|
||||||
msgcache[(irc, target, msg)] = now
|
msgcache[(irc, target, msg)] = now
|
||||||
irc.reply(msg, to=target)
|
irc.reply(msg, to=target, private=True)
|
||||||
|
|
||||||
def capab(prefix, capability):
|
def capab(prefix, capability):
|
||||||
# too bad people don't use supybot's own methods,
|
# too bad people don't use supybot's own methods,
|
||||||
|
@ -396,7 +396,7 @@ class Encyclopedia(callbacks.Plugin):
|
||||||
def doPrivmsg(self, irc, msg):
|
def doPrivmsg(self, irc, msg):
|
||||||
queue_msg = True # Queue message or send directly
|
queue_msg = True # Queue message or send directly
|
||||||
def noqueue(irc, target, msg):
|
def noqueue(irc, target, msg):
|
||||||
irc.reply(msg, to=target)
|
irc.reply(msg, to=target, private=True)
|
||||||
def myqueue(irc, target, msg):
|
def myqueue(irc, target, msg):
|
||||||
(queue if queue_msg else noqueue)(irc, target, msg)
|
(queue if queue_msg else noqueue)(irc, target, msg)
|
||||||
|
|
||||||
|
@ -572,7 +572,7 @@ class Encyclopedia(callbacks.Plugin):
|
||||||
for fact in factoids:
|
for fact in factoids:
|
||||||
L.extend(self.factoid_lookup(fact[1:], channel, nick))
|
L.extend(self.factoid_lookup(fact[1:], channel, nick))
|
||||||
for s in L:
|
for s in L:
|
||||||
irc.reply(s, to=nick)
|
irc.reply(s, to=nick, private=True)
|
||||||
|
|
||||||
def factoid_delete(self, factoid, channel, editor):
|
def factoid_delete(self, factoid, channel, editor):
|
||||||
edited = str(datetime.datetime.utcnow())
|
edited = str(datetime.datetime.utcnow())
|
||||||
|
|
|
@ -22,7 +22,7 @@ import supybot
|
||||||
import supybot.world as world
|
import supybot.world as world
|
||||||
from imp import reload
|
from imp import reload
|
||||||
|
|
||||||
__version__ = "1.8.0"
|
__version__ = "1.9.0"
|
||||||
__author__ = supybot.Author("Krytarik Raido", "krytarik", "krytarik@tuxgarage.com")
|
__author__ = supybot.Author("Krytarik Raido", "krytarik", "krytarik@tuxgarage.com")
|
||||||
__contributors__ = {
|
__contributors__ = {
|
||||||
supybot.Author("Dennis Kaarsemaker", "Seveas", "dennis@kaarsemaker.net"): ['Original Concept'],
|
supybot.Author("Dennis Kaarsemaker", "Seveas", "dennis@kaarsemaker.net"): ['Original Concept'],
|
||||||
|
|
|
@ -73,7 +73,7 @@ def queue(irc, target, msg):
|
||||||
msg = msg[:-len(oldmsg)] + 'Please see above'
|
msg = msg[:-len(oldmsg)] + 'Please see above'
|
||||||
else:
|
else:
|
||||||
msgcache[(irc, target, msg)] = now
|
msgcache[(irc, target, msg)] = now
|
||||||
irc.reply(msg, to=target)
|
irc.reply(msg, to=target, private=True)
|
||||||
|
|
||||||
class PackageInfo(callbacks.Plugin):
|
class PackageInfo(callbacks.Plugin):
|
||||||
"""Look up package information via apt-cache/apt-file"""
|
"""Look up package information via apt-cache/apt-file"""
|
||||||
|
|
Loading…
Reference in New Issue