Skip to content

Commit

Permalink
🐛 builtin plugins' metadata
Browse files Browse the repository at this point in the history
  • Loading branch information
RF-Tar-Railt committed Dec 31, 2024
1 parent e8399f6 commit c177783
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 17 deletions.
4 changes: 2 additions & 2 deletions src/nonebot_plugin_alconna/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,14 +138,14 @@
from .extension import add_global_extension as add_global_extension

__version__ = "0.54.1"

__supported_adapters__ = set(m.value for m in SupportAdapterModule.__members__.values()) # noqa: C401
__plugin_meta__ = PluginMetadata(
name="Alconna 插件",
description="提供 ArcletProject/Alconna 的 Nonebot2 适配版本与工具",
usage="matcher = on_alconna(...)",
homepage="https://github.com/nonebot/plugin-alconna",
type="library",
supported_adapters=set(SupportAdapterModule.__members__.values()),
supported_adapters=__supported_adapters__,
config=Config,
extra={
"author": "RF-Tar-Railt",
Expand Down
6 changes: 3 additions & 3 deletions src/nonebot_plugin_alconna/builtins/plugins/echo/__init__.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from nonebot.rule import to_me
from arclet.alconna import namespace
from nonebot import get_plugin_config
from nonebot.plugin import PluginMetadata, inherit_supported_adapters
from nonebot.plugin import PluginMetadata

from nonebot_plugin_alconna import Command
from nonebot_plugin_alconna import Command, __supported_adapters__
from nonebot_plugin_alconna.builtins.extensions.reply import ReplyMergeExtension

from .config import Config
Expand All @@ -17,7 +17,7 @@
type="application",
homepage="https://github.com/nonebot/plugin-alconna/blob/master/src/nonebot_plugin_alconna/builtins/plugins/echo",
config=Config,
supported_adapters=inherit_supported_adapters("nonebot_plugin_alconna"),
supported_adapters=__supported_adapters__,
)

with namespace("builtin/echo") as ns:
Expand Down
6 changes: 3 additions & 3 deletions src/nonebot_plugin_alconna/builtins/plugins/help/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
from tarina import lang
from nonebot.adapters import Bot
from nonebot import get_plugin_config
from nonebot.plugin import PluginMetadata
from importlib_metadata import PackageNotFoundError, distribution
from nonebot.plugin import PluginMetadata, inherit_supported_adapters
from arclet.alconna import (
Args,
Field,
Expand All @@ -21,7 +21,7 @@
command_manager,
)

from nonebot_plugin_alconna import UniMessage, AlconnaMatcher, referent, on_alconna
from nonebot_plugin_alconna import UniMessage, AlconnaMatcher, referent, on_alconna, __supported_adapters__

from .config import Config

Expand All @@ -32,7 +32,7 @@
type="application",
homepage="https://github.com/nonebot/plugin-alconna/blob/master/src/nonebot_plugin_alconna/builtins/plugins/help",
config=Config,
supported_adapters=inherit_supported_adapters("nonebot_plugin_alconna"),
supported_adapters=__supported_adapters__,
)


Expand Down
6 changes: 3 additions & 3 deletions src/nonebot_plugin_alconna/builtins/plugins/lang.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
from nonebot.plugin import PluginMetadata, inherit_supported_adapters
from nonebot.plugin import PluginMetadata
from arclet.alconna import Args, Field, Option, Alconna, CommandMeta, namespace

from nonebot_plugin_alconna.i18n import Lang, lang
from nonebot_plugin_alconna import Match, UniMessage, on_alconna
from nonebot_plugin_alconna import Match, UniMessage, on_alconna, __supported_adapters__

__plugin_meta__ = PluginMetadata(
name="lang",
Expand All @@ -11,7 +11,7 @@
type="application",
homepage="https://github.com/nonebot/plugin-alconna/blob/master/src/nonebot_plugin_alconna/builtins/plugins/lang.py",
config=None,
supported_adapters=inherit_supported_adapters("nonebot_plugin_alconna"),
supported_adapters=__supported_adapters__,
)

with namespace("builtin/lang") as ns:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
from nonebot.adapters import Bot
from nonebot import get_plugin_config
from nonebot.permission import SUPERUSER
from nonebot.plugin import PluginMetadata, inherit_supported_adapters
from nonebot.plugin import PluginMetadata
from arclet.alconna import Args, Field, Option, Alconna, Arparma, CommandMeta, namespace, store_true, command_manager

from nonebot_plugin_alconna import on_alconna
from nonebot_plugin_alconna import on_alconna, __supported_adapters__

from .config import Config

Expand All @@ -18,7 +18,7 @@
type="application",
homepage="https://github.com/nonebot/plugin-alconna/blob/master/src/nonebot_plugin_alconna/builtins/plugins/switch",
config=Config,
supported_adapters=inherit_supported_adapters("nonebot_plugin_alconna"),
supported_adapters=__supported_adapters__,
)


Expand Down
6 changes: 3 additions & 3 deletions src/nonebot_plugin_alconna/builtins/plugins/with/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@

from arclet.alconna import namespace
from nonebot import get_plugin_config
from nonebot.plugin import PluginMetadata, inherit_supported_adapters
from nonebot.plugin import PluginMetadata

from nonebot_plugin_alconna import Match, Command, MsgTarget, add_global_extension
from nonebot_plugin_alconna import Match, Command, MsgTarget, add_global_extension, __supported_adapters__

from .config import Config
from .extension import PrefixAppendExtension
Expand All @@ -18,7 +18,7 @@
type="application",
homepage="https://github.com/nonebot/plugin-alconna/blob/master/src/nonebot_plugin_alconna/builtins/plugins/with",
config=Config,
supported_adapters=inherit_supported_adapters("nonebot_plugin_alconna"),
supported_adapters=__supported_adapters__,
)


Expand Down

0 comments on commit c177783

Please sign in to comment.