feat: auto_update 插件与监督进程入口

This commit is contained in:
snowy-yang committed 2026-09-06 00:29:35 +08:00
1 parent 320ecfc0a7
commit a68ae28960
8 files changed
+382 -4

No files matched your search

+19
View File
@@ -0,0 +1,19 @@
"""机器人入口
两种启动方式:
- 开发调试:nb run --reload (文件变化自动重载,不走本入口)
- 正式运行:python bot.py (监督进程模式,auto_update 插件拉取更新后可优雅重启)
"""
import nonebot
nonebot.init()
nonebot.load_from_toml("pyproject.toml") # 适配器 + 第三方插件 + 本地插件目录
from src.plugins.auto_update.reloader import install_reloader
install_reloader()
if __name__ == "__main__":
nonebot.run()