diff --git a/sopel_SpiceBot_Core_1/SBCore/commands/__init__.py b/sopel_SpiceBot_Core_1/SBCore/commands/__init__.py index ea63295..14cd256 100644 --- a/sopel_SpiceBot_Core_1/SBCore/commands/__init__.py +++ b/sopel_SpiceBot_Core_1/SBCore/commands/__init__.py @@ -16,8 +16,6 @@ class Commands(): commands_list.append({ "name": command.name, "aliases": command.aliases, - "class": str(command.__class__), - "dir": str(dir(command.__class__)) }) return commands_list @@ -29,7 +27,6 @@ class Commands(): commands_list.append({ "name": command.name, "aliases": command.aliases, - "class": str(command.__class__) }) return commands_list @@ -41,7 +38,6 @@ class Commands(): commands_list.append({ "name": command.name, "aliases": command.aliases, - "class": str(command.__class__) }) return commands_list diff --git a/sopel_SpiceBot_Runtime_Nickname_Commands/__init__.py b/sopel_SpiceBot_Runtime_Nickname_Commands/__init__.py index bcaeae1..b89b962 100644 --- a/sopel_SpiceBot_Runtime_Nickname_Commands/__init__.py +++ b/sopel_SpiceBot_Runtime_Nickname_Commands/__init__.py @@ -14,40 +14,9 @@ def sb_test_commands(bot, trigger): bot.say("%s" % trigger.raw) -@plugin.nickname_command('command_groups') +@plugin.nickname_command('plugins') def sb_test_command_groups(bot, trigger): - - plugin_commands = itertools.chain( - bot.rules.get_all_commands(), - bot.rules.get_all_action_commands(), - bot.rules.get_all_nick_commands(), - ) - - for plugin_name, commands in plugin_commands: - for command in commands.values(): - bot.say(str(command.name)) - sb.osd(str(dir(command)), trigger.sender) - return - - commands = ( - (command, command.get_doc(), command.get_usages()) - for plugin_name, commands in plugin_commands - for command in commands.values() - ) - - for command, doc, usages in commands: - bot.say(str(dir(command))) - return - - realcommands = dict( - (name, (doc.splitlines(), [u['text'] for u in usages])) - for command, doc, usages in commands - for name in ((command.name,) + command.aliases) - ) - - sb.osd(str(realcommands), trigger.sender) - - # sb.osd(msgs, trigger.sender) + bot.say(str(dir(bot._plugins))) @prerun()