test
This commit is contained in:
parent
e86ea9494c
commit
e32f128aef
@ -22,5 +22,6 @@ install_requires =
|
|||||||
|
|
||||||
[options.entry_points]
|
[options.entry_points]
|
||||||
sopel.plugins =
|
sopel.plugins =
|
||||||
SpiceBotCore = sopel_SpiceBotCore
|
SpiceBotCore = sopel_SpiceBot_Core_1
|
||||||
SpiceBotStartup = sopel_SpiceBotStartup
|
SpiceBotPrerun = sopel_SpiceBot_Core_Prerun
|
||||||
|
SpiceBotStartup = sopel_SpiceBot_Core_Startup
|
||||||
|
|||||||
@ -7,10 +7,7 @@ from __future__ import unicode_literals, absolute_import, division, print_functi
|
|||||||
import os
|
import os
|
||||||
import pathlib
|
import pathlib
|
||||||
|
|
||||||
from sopel import plugin
|
|
||||||
|
|
||||||
from .SBCore import SpiceBotCore_OBJ
|
from .SBCore import SpiceBotCore_OBJ
|
||||||
from .SBCore.prerun import prerun
|
|
||||||
|
|
||||||
SCRIPT_DIR = pathlib.Path(os.path.dirname(os.path.abspath(__file__)))
|
SCRIPT_DIR = pathlib.Path(os.path.dirname(os.path.abspath(__file__)))
|
||||||
|
|
||||||
@ -19,13 +16,3 @@ sb = SpiceBotCore_OBJ(SCRIPT_DIR)
|
|||||||
|
|
||||||
def setup(bot):
|
def setup(bot):
|
||||||
sb.setup(bot)
|
sb.setup(bot)
|
||||||
|
|
||||||
|
|
||||||
@prerun('nickname')
|
|
||||||
@plugin.nickname_command('test')
|
|
||||||
def sb_nickname_command(bot, trigger, sb):
|
|
||||||
bot.say("Testing the bot")
|
|
||||||
bot.say("Attributes: %s" % [x for x in dir(sb) if not x.startswith("__")])
|
|
||||||
bot.say("%s" % sb.versions.dict)
|
|
||||||
|
|
||||||
sb.osd("test", trigger.sender)
|
|
||||||
@ -1,6 +1,6 @@
|
|||||||
import functools
|
import functools
|
||||||
|
|
||||||
from sopel_SpiceBotCore import sb
|
from sopel_SpiceBot_Core_1 import sb
|
||||||
|
|
||||||
|
|
||||||
def prerun(t_command_type='module'):
|
def prerun(t_command_type='module'):
|
||||||
@ -8,7 +8,7 @@ from threading import Thread
|
|||||||
|
|
||||||
from sopel import plugin
|
from sopel import plugin
|
||||||
|
|
||||||
from sopel_SpiceBotCore import sb
|
from sopel_SpiceBot_Core_1 import sb
|
||||||
|
|
||||||
|
|
||||||
"""
|
"""
|
||||||
15
sopel_SpiceBot_Runtime_Commands/__init__.py
Normal file
15
sopel_SpiceBot_Runtime_Commands/__init__.py
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
|
||||||
|
|
||||||
|
from sopel import plugin
|
||||||
|
|
||||||
|
from sopel_SpiceBot_Core_1.SBCore.prerun import prerun
|
||||||
|
|
||||||
|
|
||||||
|
@prerun('nickname')
|
||||||
|
@plugin.nickname_command('test')
|
||||||
|
def sb_nickname_command(bot, trigger, sb):
|
||||||
|
bot.say("Testing the bot")
|
||||||
|
bot.say("Attributes: %s" % [x for x in dir(sb) if not x.startswith("__")])
|
||||||
|
bot.say("%s" % sb.versions.dict)
|
||||||
|
|
||||||
|
sb.osd("test", trigger.sender)
|
||||||
Loading…
Reference in New Issue
Block a user