This commit is contained in:
deathbybandaid 2022-05-13 08:10:55 -04:00
parent 41f4fb18c1
commit d2205d01c2

View File

@ -4,6 +4,10 @@ def setup(bot, trigger, comrun):
return return
""" """
`bot.rules.register_command(Command('name', prefix=settings_prefix, plugin="your_plugin_id", ...))` `bot.rules.register_command(Command('name', prefix=settings_prefix, plugin="your_plugin_id", ...))`
All you need is to create and register an instance of `sopel.plugins.rules.Command` (or use a subclass) with `bot.rules.register_command(generated_command)`.
do a for loop and register commands with the query prefix set in the configuration do a for loop and register commands with the query prefix set in the configuration
unregister built-in commands unregister built-in commands