chore: 统一代码风格并进行现代化改造

本次提交主要包含以下内容:
- **代码风格统一**:对多个文件进行了格式化,包括移除多余的空行、调整导入顺序、统一字符串引号等,以提高代码一致性和可读性。
- **类型提示现代化**:在多个文件中将旧的 `typing` 模块类型提示(如 `Optional[T]`、`List[T]`、`Union[T, U]`)更新为现代 Python 语法(`T | None`、`list[T]`、`T | U`)。
- **f-string 格式化**:在 `scripts/convert_manifest.py` 中,将 `.format()` 调用更新为更现代和易读的 f-string `!r` 表示法。
- **文件末尾换行符**:为多个文件添加或修正了文件末尾的换行符,遵循 POSIX 标准。
This commit is contained in:
minecraft1024a
2025-10-25 13:31:22 +08:00
parent 5fc9d1b9da
commit 3c4a3b0428
30 changed files with 126 additions and 124 deletions

View File

@@ -49,11 +49,11 @@ __plugin_meta__ = PluginMetadata(
name="{plugin_name}",
description="{description}",
usage="暂无说明",
type={repr(plugin_type)},
type={plugin_type!r},
version="{version}",
author="{author}",
license={repr(license_type)},
repository_url={repr(repository_url)},
license={license_type!r},
repository_url={repository_url!r},
keywords={keywords},
categories={categories},
)