feat(plugin): 兼容 alpha 版本并更新插件版本限制

- 在版本比较器中增加对 alpha 版本号的兼容性处理,现在可以正确解析如 `0.10.0-alpha-1` 格式的版本。
This commit is contained in:
minecraft1024a
2025-08-22 13:03:36 +08:00
parent ce2e5bd199
commit 7531ed9ba8
2 changed files with 3 additions and 2 deletions

View File

@@ -54,6 +54,7 @@ class VersionComparator:
# 移除snapshot部分
normalized = re.sub(r"-snapshot\.\d+", "", version.strip())
normalized = re.sub(r"-alpha\-\d+", "", version.strip())
# 确保版本号格式正确
if not re.match(r"^\d+(\.\d+){0,2}$", normalized):

View File

@@ -11,7 +11,7 @@
"host_application": {
"min_version": "0.8.0",
"max_version": "0.10.0"
"max_version": "0.11.0"
},
"homepage_url": "https://github.com/MaiBot-Plus/MaiMbot-Pro-Max",
"repository_url": "https://github.com/MaiBot-Plus/MaiMbot-Pro-Max",
@@ -47,4 +47,4 @@
"历史记录避重"
]
}
}
}