Began Relay.reconnect and changed names to nicks.

This commit is contained in:
Jeremy Fincher 2004-03-30 21:14:34 +00:00
parent 1d27db449b
commit d4c7db7a93
2 changed files with 20 additions and 1 deletions

View File

@ -1,6 +1,10 @@
* Changed Relay.names to Relay.nicks, to be consistent with
Channel.nicks.
* Added supybot.brackets, a configuration variable for specifying
which set of matching brackets to use for nested commands. Valid
values are [] (the default), {}, <>, and ().
* Added a configuration variable to ChannelLogger, timestamp,
which determines whether the bot will timestamp its logfiles.
This is a channel-specific variable, of course.

View File

@ -177,6 +177,21 @@ class Relay(callbacks.Privmsg):
irc.replySuccess()
connect = privmsgs.checkCapability(connect, 'owner')
def reconnect(self, irc, msg, args):
"""<network>
Reconnects the bot to <network> when it has become disconnected.
"""
network = privmsgs.getArgs(args)
try:
toReconnect = self.ircs[network]
except KeyError:
irc.error('I\'m not connected to %s.' % network)
return
toReeconnect.driver.reconnect()
irc.replySuccess()
reconnect = privmsgs.checkCapability(reconnect, 'owner')
def disconnect(self, irc, msg, args):
"""<network>
@ -283,7 +298,7 @@ class Relay(callbacks.Privmsg):
self.ircs[network].queueMsg(ircmsgs.privmsg(channel, text))
say = privmsgs.checkCapability(say, 'admin')
def names(self, irc, msg, args):
def nicks(self, irc, msg, args):
"""[<channel>] (only if not sent in the channel itself.)
The <channel> argument is only necessary if the message isn't sent on