mirror of
https://github.com/LiteyukiStudio/nonebot-plugin-marshoai.git
synced 2025-06-19 18:17:46 +00:00
argot test command
This commit is contained in:
parent
544ef596df
commit
707f017718
@ -1,10 +1,11 @@
|
|||||||
import os
|
import os
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
|
|
||||||
from nonebot import get_driver, logger, require
|
from nonebot import get_driver, logger, on_command, require
|
||||||
from nonebot.adapters import Bot, Event
|
from nonebot.adapters import Bot, Event
|
||||||
from nonebot.matcher import Matcher
|
from nonebot.matcher import Matcher
|
||||||
from nonebot.typing import T_State
|
from nonebot.typing import T_State
|
||||||
|
from nonebot_plugin_argot import add_argot, get_message_id
|
||||||
|
|
||||||
from nonebot_plugin_marshoai.plugin.load import reload_plugin
|
from nonebot_plugin_marshoai.plugin.load import reload_plugin
|
||||||
|
|
||||||
@ -48,6 +49,21 @@ function_call = on_alconna(
|
|||||||
permission=SUPERUSER,
|
permission=SUPERUSER,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
argot_test = on_command("argot", permission=SUPERUSER)
|
||||||
|
|
||||||
|
|
||||||
|
@argot_test.handle()
|
||||||
|
async def _():
|
||||||
|
await argot_test.send(
|
||||||
|
"aa",
|
||||||
|
argot={
|
||||||
|
"name": "test",
|
||||||
|
"command": "test",
|
||||||
|
"segment": f"{os.getcwd()}",
|
||||||
|
"expired_at": 1000,
|
||||||
|
},
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
@function_call.assign("list")
|
@function_call.assign("list")
|
||||||
async def list_functions():
|
async def list_functions():
|
||||||
|
Loading…
x
Reference in New Issue
Block a user