update some .help text
This commit is contained in:
parent
3d047bb0cc
commit
5b68793f4f
|
@ -5,7 +5,7 @@
|
||||||
:synopsis: Spam chat with awesome ascii texts
|
:synopsis: Spam chat with awesome ascii texts
|
||||||
"""
|
"""
|
||||||
|
|
||||||
from pyircbot.modulebase import ModuleBase, hook, command
|
from pyircbot.modulebase import ModuleBase, command
|
||||||
from threading import Thread
|
from threading import Thread
|
||||||
from glob import iglob
|
from glob import iglob
|
||||||
from collections import defaultdict
|
from collections import defaultdict
|
||||||
|
@ -14,6 +14,7 @@ import re
|
||||||
import os
|
import os
|
||||||
import json
|
import json
|
||||||
from textwrap import wrap
|
from textwrap import wrap
|
||||||
|
from pyircbot.modules.ModInfo import info
|
||||||
|
|
||||||
|
|
||||||
RE_ASCII_FNAME = re.compile(r'^[a-zA-Z0-9\-_]+$')
|
RE_ASCII_FNAME = re.compile(r'^[a-zA-Z0-9\-_]+$')
|
||||||
|
@ -31,7 +32,7 @@ class ASCII(ModuleBase):
|
||||||
self.running_asciis = defaultdict(lambda: None)
|
self.running_asciis = defaultdict(lambda: None)
|
||||||
self.killed_channels = defaultdict(lambda: False)
|
self.killed_channels = defaultdict(lambda: False)
|
||||||
|
|
||||||
# @hook("PRIVMSG")
|
@info("listascii list available asciis", cmds=["listascii"])
|
||||||
@command("listascii")
|
@command("listascii")
|
||||||
def cmd_listascii(self, msg, cmd):
|
def cmd_listascii(self, msg, cmd):
|
||||||
"""
|
"""
|
||||||
|
@ -47,11 +48,9 @@ class ASCII(ModuleBase):
|
||||||
self.bot.act_PRIVMSG(msg.args[0], "...and {} more".format(len(fnames) - self.config.get("list_max")))
|
self.bot.act_PRIVMSG(msg.args[0], "...and {} more".format(len(fnames) - self.config.get("list_max")))
|
||||||
return
|
return
|
||||||
|
|
||||||
|
@info("ascii <name> print an ascii", cmds=["ascii"])
|
||||||
@command("ascii", require_args=True)
|
@command("ascii", require_args=True)
|
||||||
def cmd_ascii(self, msg, cmd):
|
def cmd_ascii(self, msg, cmd):
|
||||||
# import ipdb
|
|
||||||
# ipdb.set_trace()
|
|
||||||
# Send out an ascii
|
|
||||||
if self.channel_busy(msg.args[0]):
|
if self.channel_busy(msg.args[0]):
|
||||||
return
|
return
|
||||||
|
|
||||||
|
@ -69,6 +68,7 @@ class ASCII(ModuleBase):
|
||||||
except FileNotFoundError:
|
except FileNotFoundError:
|
||||||
return
|
return
|
||||||
|
|
||||||
|
@info("stopascii stop the currently scrolling ascii", cmds=["stopascii"])
|
||||||
@command("stopascii")
|
@command("stopascii")
|
||||||
def cmd_stopascii(self, msg, cmd):
|
def cmd_stopascii(self, msg, cmd):
|
||||||
"""
|
"""
|
||||||
|
@ -119,6 +119,7 @@ class ASCII(ModuleBase):
|
||||||
del self.running_asciis[channel]
|
del self.running_asciis[channel]
|
||||||
del self.killed_channels[channel]
|
del self.killed_channels[channel]
|
||||||
|
|
||||||
|
@info("asciiedit <args> customize an ascii with input", cmds=["asciiedit"])
|
||||||
@command("asciiedit", require_args=True)
|
@command("asciiedit", require_args=True)
|
||||||
def cmd_asciiedit(self, msg, cmd):
|
def cmd_asciiedit(self, msg, cmd):
|
||||||
ascii_name = cmd.args.pop(0)
|
ascii_name = cmd.args.pop(0)
|
||||||
|
|
|
@ -135,6 +135,7 @@ class Calc(ModuleBase):
|
||||||
randCalc["definition"], randCalc["by"]))
|
randCalc["definition"], randCalc["by"]))
|
||||||
self.updateTimeSince(channel, "calc")
|
self.updateTimeSince(channel, "calc")
|
||||||
|
|
||||||
|
@info("match <value> search for facts by key", cmds=["match"])
|
||||||
@command("match", require_args=True)
|
@command("match", require_args=True)
|
||||||
def cmd_match(self, msg, cmd):
|
def cmd_match(self, msg, cmd):
|
||||||
if self.config["delayMatch"] > 0 and self.timeSince(msg.args[0], "match") < self.config["delayMatch"]:
|
if self.config["delayMatch"] > 0 and self.timeSince(msg.args[0], "match") < self.config["delayMatch"]:
|
||||||
|
|
Loading…
Reference in New Issue