From 9f28b4625c71c6c0cf687d745b5c127195bd1e86 Mon Sep 17 00:00:00 2001 From: StarHeartHunt Date: Mon, 16 Sep 2024 10:58:06 +0800 Subject: [PATCH] :memo: add frontmatter to use md --- nonebot/__init__.py | 2 ++ nonebot/adapters/__init__.py | 2 ++ nonebot/compat.py | 2 ++ nonebot/config.py | 2 ++ nonebot/consts.py | 2 ++ nonebot/dependencies/__init__.py | 2 ++ nonebot/dependencies/utils.py | 2 ++ nonebot/drivers/__init__.py | 2 ++ nonebot/drivers/aiohttp.py | 2 ++ nonebot/drivers/fastapi.py | 2 ++ nonebot/drivers/httpx.py | 2 ++ nonebot/drivers/none.py | 2 ++ nonebot/drivers/quart.py | 2 ++ nonebot/drivers/websockets.py | 2 ++ nonebot/exception.py | 2 ++ nonebot/log.py | 2 ++ nonebot/matcher.py | 2 ++ nonebot/message.py | 2 ++ nonebot/params.py | 2 ++ nonebot/permission.py | 2 ++ nonebot/plugin/__init__.py | 2 ++ nonebot/plugin/load.py | 2 ++ nonebot/plugin/manager.py | 2 ++ nonebot/plugin/model.py | 2 ++ nonebot/plugin/on.py | 2 ++ nonebot/rule.py | 2 ++ nonebot/typing.py | 2 ++ nonebot/utils.py | 2 ++ 28 files changed, 56 insertions(+) diff --git a/nonebot/__init__.py b/nonebot/__init__.py index e413403e7218..65c8afc9ea42 100644 --- a/nonebot/__init__.py +++ b/nonebot/__init__.py @@ -39,6 +39,8 @@ - `require` => {ref}``require` ` FrontMatter: + mdx: + format: md sidebar_position: 0 description: nonebot 模块 """ diff --git a/nonebot/adapters/__init__.py b/nonebot/adapters/__init__.py index f61cbfc3decc..3eb2fcacb5b4 100644 --- a/nonebot/adapters/__init__.py +++ b/nonebot/adapters/__init__.py @@ -3,6 +3,8 @@ 使用 {ref}`nonebot.drivers.Driver.register_adapter` 注册适配器。 FrontMatter: + mdx: + format: md sidebar_position: 0 description: nonebot.adapters 模块 """ diff --git a/nonebot/compat.py b/nonebot/compat.py index 8b73aef9b440..9dbdd02a0cbd 100644 --- a/nonebot/compat.py +++ b/nonebot/compat.py @@ -3,6 +3,8 @@ 为兼容 Pydantic V1 与 V2 版本,定义了一系列兼容函数与类供使用。 FrontMatter: + mdx: + format: md sidebar_position: 16 description: nonebot.compat 模块 """ diff --git a/nonebot/config.py b/nonebot/config.py index 4e828ec8a2fd..11f3fed1810f 100644 --- a/nonebot/config.py +++ b/nonebot/config.py @@ -7,6 +7,8 @@ 详情见 [`pydantic Field Type`](https://pydantic-docs.helpmanual.io/usage/types/) 文档。 FrontMatter: + mdx: + format: md sidebar_position: 1 description: nonebot.config 模块 """ diff --git a/nonebot/consts.py b/nonebot/consts.py index f64d5fc4587b..701307d3f18a 100644 --- a/nonebot/consts.py +++ b/nonebot/consts.py @@ -1,6 +1,8 @@ """本模块包含了 NoneBot 事件处理过程中使用到的常量。 FrontMatter: + mdx: + format: md sidebar_position: 9 description: nonebot.consts 模块 """ diff --git a/nonebot/dependencies/__init__.py b/nonebot/dependencies/__init__.py index 4d462a084cb8..1ff797647d02 100644 --- a/nonebot/dependencies/__init__.py +++ b/nonebot/dependencies/__init__.py @@ -1,6 +1,8 @@ """本模块模块实现了依赖注入的定义与处理。 FrontMatter: + mdx: + format: md sidebar_position: 0 description: nonebot.dependencies 模块 """ diff --git a/nonebot/dependencies/utils.py b/nonebot/dependencies/utils.py index 55f490ccd7bd..35954a185bb5 100644 --- a/nonebot/dependencies/utils.py +++ b/nonebot/dependencies/utils.py @@ -1,5 +1,7 @@ """ FrontMatter: + mdx: + format: md sidebar_position: 1 description: nonebot.dependencies.utils 模块 """ diff --git a/nonebot/drivers/__init__.py b/nonebot/drivers/__init__.py index f318fc844c37..5c80f8d8ae4b 100644 --- a/nonebot/drivers/__init__.py +++ b/nonebot/drivers/__init__.py @@ -3,6 +3,8 @@ 各驱动请继承以下基类。 FrontMatter: + mdx: + format: md sidebar_position: 0 description: nonebot.drivers 模块 """ diff --git a/nonebot/drivers/aiohttp.py b/nonebot/drivers/aiohttp.py index b2a207bbb4ca..388a70fc7e71 100644 --- a/nonebot/drivers/aiohttp.py +++ b/nonebot/drivers/aiohttp.py @@ -11,6 +11,8 @@ ::: FrontMatter: + mdx: + format: md sidebar_position: 2 description: nonebot.drivers.aiohttp 模块 """ diff --git a/nonebot/drivers/fastapi.py b/nonebot/drivers/fastapi.py index 36897184c398..69b0a45b7a79 100644 --- a/nonebot/drivers/fastapi.py +++ b/nonebot/drivers/fastapi.py @@ -11,6 +11,8 @@ ::: FrontMatter: + mdx: + format: md sidebar_position: 1 description: nonebot.drivers.fastapi 模块 """ diff --git a/nonebot/drivers/httpx.py b/nonebot/drivers/httpx.py index 68eed464853b..e226ce142f44 100644 --- a/nonebot/drivers/httpx.py +++ b/nonebot/drivers/httpx.py @@ -11,6 +11,8 @@ ::: FrontMatter: + mdx: + format: md sidebar_position: 3 description: nonebot.drivers.httpx 模块 """ diff --git a/nonebot/drivers/none.py b/nonebot/drivers/none.py index 615de8e61eab..8cc0c1b205f7 100644 --- a/nonebot/drivers/none.py +++ b/nonebot/drivers/none.py @@ -5,6 +5,8 @@ ::: FrontMatter: + mdx: + format: md sidebar_position: 6 description: nonebot.drivers.none 模块 """ diff --git a/nonebot/drivers/quart.py b/nonebot/drivers/quart.py index 76bc8092bc40..fd0c9edbf8fb 100644 --- a/nonebot/drivers/quart.py +++ b/nonebot/drivers/quart.py @@ -11,6 +11,8 @@ ::: FrontMatter: + mdx: + format: md sidebar_position: 5 description: nonebot.drivers.quart 模块 """ diff --git a/nonebot/drivers/websockets.py b/nonebot/drivers/websockets.py index 4790f22decee..156a7e2841bc 100644 --- a/nonebot/drivers/websockets.py +++ b/nonebot/drivers/websockets.py @@ -11,6 +11,8 @@ ::: FrontMatter: + mdx: + format: md sidebar_position: 4 description: nonebot.drivers.websockets 模块 """ diff --git a/nonebot/exception.py b/nonebot/exception.py index 4d45ef7ce417..30a9c74360ed 100644 --- a/nonebot/exception.py +++ b/nonebot/exception.py @@ -25,6 +25,8 @@ ``` FrontMatter: + mdx: + format: md sidebar_position: 10 description: nonebot.exception 模块 """ diff --git a/nonebot/log.py b/nonebot/log.py index a0f6bceb3059..fb61613d6dc1 100644 --- a/nonebot/log.py +++ b/nonebot/log.py @@ -8,6 +8,8 @@ [loguru]: https://github.com/Delgan/loguru FrontMatter: + mdx: + format: md sidebar_position: 7 description: nonebot.log 模块 """ diff --git a/nonebot/matcher.py b/nonebot/matcher.py index 9bbe15e087e7..fc348cd1b4ce 100644 --- a/nonebot/matcher.py +++ b/nonebot/matcher.py @@ -1,6 +1,8 @@ """本模块实现事件响应器的创建与运行,并提供一些快捷方法来帮助用户更好的与机器人进行对话。 FrontMatter: + mdx: + format: md sidebar_position: 3 description: nonebot.matcher 模块 """ diff --git a/nonebot/message.py b/nonebot/message.py index ed8433726d49..710afdbc87c1 100644 --- a/nonebot/message.py +++ b/nonebot/message.py @@ -3,6 +3,8 @@ NoneBot 内部处理并按优先级分发事件给所有事件响应器,提供了多个插槽以进行事件的预处理等。 FrontMatter: + mdx: + format: md sidebar_position: 2 description: nonebot.message 模块 """ diff --git a/nonebot/params.py b/nonebot/params.py index 45955b45d564..6e8635dee0d0 100644 --- a/nonebot/params.py +++ b/nonebot/params.py @@ -1,6 +1,8 @@ """本模块定义了依赖注入的各类参数。 FrontMatter: + mdx: + format: md sidebar_position: 4 description: nonebot.params 模块 """ diff --git a/nonebot/permission.py b/nonebot/permission.py index 69500ad14aed..fa89622eb813 100644 --- a/nonebot/permission.py +++ b/nonebot/permission.py @@ -5,6 +5,8 @@ 只要有一个 `PermissionChecker` 检查结果为 `True` 时就会继续运行。 FrontMatter: + mdx: + format: md sidebar_position: 6 description: nonebot.permission 模块 """ diff --git a/nonebot/plugin/__init__.py b/nonebot/plugin/__init__.py index 81913529efe7..7ef49623ab21 100644 --- a/nonebot/plugin/__init__.py +++ b/nonebot/plugin/__init__.py @@ -32,6 +32,8 @@ - `PluginMetadata` => {ref}``PluginMetadata` ` FrontMatter: + mdx: + format: md sidebar_position: 0 description: nonebot.plugin 模块 """ diff --git a/nonebot/plugin/load.py b/nonebot/plugin/load.py index 66f28d0dc4fb..173e357c07b1 100644 --- a/nonebot/plugin/load.py +++ b/nonebot/plugin/load.py @@ -1,6 +1,8 @@ """本模块定义插件加载接口。 FrontMatter: + mdx: + format: md sidebar_position: 1 description: nonebot.plugin.load 模块 """ diff --git a/nonebot/plugin/manager.py b/nonebot/plugin/manager.py index 4f613c7cace4..215cf7402ba9 100644 --- a/nonebot/plugin/manager.py +++ b/nonebot/plugin/manager.py @@ -3,6 +3,8 @@ 参考: [import hooks](https://docs.python.org/3/reference/import.html#import-hooks), [PEP302](https://www.python.org/dev/peps/pep-0302/) FrontMatter: + mdx: + format: md sidebar_position: 5 description: nonebot.plugin.manager 模块 """ diff --git a/nonebot/plugin/model.py b/nonebot/plugin/model.py index 3b6d8a01d3f2..67f4ff022a5e 100644 --- a/nonebot/plugin/model.py +++ b/nonebot/plugin/model.py @@ -1,6 +1,8 @@ """本模块定义插件相关信息。 FrontMatter: + mdx: + format: md sidebar_position: 3 description: nonebot.plugin.model 模块 """ diff --git a/nonebot/plugin/on.py b/nonebot/plugin/on.py index ba8ca6ac8556..bcd04490ac9f 100644 --- a/nonebot/plugin/on.py +++ b/nonebot/plugin/on.py @@ -1,6 +1,8 @@ """本模块定义事件响应器便携定义函数。 FrontMatter: + mdx: + format: md sidebar_position: 2 description: nonebot.plugin.on 模块 """ diff --git a/nonebot/rule.py b/nonebot/rule.py index 44f4d25b5039..6c2821b8abc4 100644 --- a/nonebot/rule.py +++ b/nonebot/rule.py @@ -5,6 +5,8 @@ 只有当所有 `RuleChecker` 检查结果为 `True` 时继续运行。 FrontMatter: + mdx: + format: md sidebar_position: 5 description: nonebot.rule 模块 """ diff --git a/nonebot/typing.py b/nonebot/typing.py index 60d762efa59c..e941cf1d09c7 100644 --- a/nonebot/typing.py +++ b/nonebot/typing.py @@ -6,6 +6,8 @@ [`typing`](https://docs.python.org/3/library/typing.html)。 FrontMatter: + mdx: + format: md sidebar_position: 11 description: nonebot.typing 模块 """ diff --git a/nonebot/utils.py b/nonebot/utils.py index 1de3bdf2abd1..111697c0fcd0 100644 --- a/nonebot/utils.py +++ b/nonebot/utils.py @@ -1,6 +1,8 @@ """本模块包含了 NoneBot 的一些工具函数 FrontMatter: + mdx: + format: md sidebar_position: 8 description: nonebot.utils 模块 """