nonebot2/plugins/base.py

16 lines
349 B
Python
Raw Normal View History

2018-06-15 15:00:58 +08:00
from aiocqhttp.message import unescape
2018-06-15 06:58:24 +08:00
import none
2018-06-15 15:00:58 +08:00
from none import permissions as perm
from none.helpers import send
@none.on_command('echo')
async def _(bot, ctx, session):
await send(bot, ctx, session.arg)
2018-06-15 06:58:24 +08:00
2018-06-15 15:00:58 +08:00
@none.on_command('say', permission=perm.SUPERUSER)
2018-06-15 10:40:53 +08:00
async def _(bot, ctx, session):
2018-06-15 15:00:58 +08:00
await send(bot, ctx, unescape(session.arg))