Misc tweaks and fixes

dave 6 years ago
parent d9914ca104
commit 7379d03153

@ -98,7 +98,7 @@ class PyIRCBotSub(PrimitiveBot):
if __name__ == "__main__":
format="%(asctime)-15s %(levelname)-8s %(filename)s:%(lineno)d %(message)s")
log = logging.getLogger('main')
@ -108,7 +108,7 @@ if __name__ == "__main__":
parser.add_argument("-s", "--server", default="localhost", help="Msgbus server address")
parser.add_argument("-p", "--port", default=7100, type=int, help="Msgbus server port")
parser.add_argument("-n", "--name", default="default", help="bot name")
parser.add_argument("--debug", action="store_true", help="")
parser.add_argument("--debug", action="store_true", help="increase logging level")
args = parser.parse_args()
if args.debug:

@ -63,6 +63,7 @@ class ModInfo(ModuleBase):
for modname, module, helptext, helpcommands in self.iter_modules():
self.bot.act_PRIVMSG(msg.args[0], "{}: {}{}".format(modname, command.prefix, helptext))
@info("helpindex show a short list of all commands", cmds=["helpindex"])
def cmd_helpindex(self, msg, cmd):

@ -8,6 +8,7 @@
from time import time
from math import floor
from pyircbot.modulebase import ModuleBase, regex
from pyircbot.modules.ModInfo import info
import cherrypy
from threading import Thread
from twilio.rest import Client
@ -133,6 +134,7 @@ class SMS(ModuleBase):
@info("text-<name> text somebody on the VIP list", cmds=["text"])
@regex(r'(?:^\.text\-([a-zA-Z0-9]+)(?:\s+(.+))?)', types=['PRIVMSG'])
def cmd_text(self, msg, match):

@ -61,7 +61,7 @@ class Tell(ModuleBase):
# Delete
self.db.query("DELETE FROM `tells` WHERE `id`=?", (tell["id"],))
@info(".tell <person> <message> relay a message when the target is online", cmds=["tell"])
@info("tell <person> <message> relay a message when the target is online", cmds=["tell"])
@command("tell", allow_private=True)
def tellcmds(self, msg, cmd):
if len(cmd.args) < 2: