From 0a49a92f37b93ecb91457dd0bfeb782e8d5633fe Mon Sep 17 00:00:00 2001 From: Richard Darst Date: Fri, 26 Jun 2009 18:40:17 +0000 Subject: Initial checkin of supybot-based config method - this simply proxies all string attributes of the Config class to the supybot config namespace supybot.plugins.MeetBot.* When you adjust them in supybot, the MeetBot methods see the changes. - To enable, you must set supybot.plugins.MeetBot.enableSupybotBasedConfig to True, and then reload MeetBot. Then "config list supybot.plugins.MeetBot" and you'll see a bunch of variables for you to change. - To-do: think about supybot config stomping changes to defaults, and implement channel-based config. darcs-hash:20090626184017-82ea9-c24fcb02c54fd848de6ce5b212b1a48fcf42d970.gz --- (limited to 'plugin.py') diff --git a/plugin.py b/plugin.py index 0acf18c..fa82b0e 100644 --- a/plugin.py +++ b/plugin.py @@ -38,6 +38,8 @@ import supybot.ircmsgs as ircmsgs import time import meeting meeting = reload(meeting) +import supybotconfig +supybotconfig = reload(supybotconfig) # By doing this, we can not lose all of our meetings across plugin # reloads. But, of course, you can't change the source too @@ -97,6 +99,8 @@ class MeetBot(callbacks.Plugin): irc.sendMsg(ircmsgs.privmsg(channel, x)) M._setTopic = _setTopic M._sendReply = _sendReply + # callback to get supybot registry values. + M._registryValue = self.registryValue # If there is no meeting going on, then we quit if M is None: return # Add line to our meeting buffer. -- cgit v0.9.1