chore: add ruff checks

This commit is contained in:
chengma
2026-07-07 15:11:40 +08:00
parent 862f791fde
commit 6e2347e1c8
13 changed files with 81 additions and 16 deletions
+4 -2
View File
@@ -32,15 +32,17 @@
```powershell
python -m pip install -r requirements.txt
python -m pip install -r requirements-dev.txt
python -m ruff check app tests main.py
python -m compileall app main.py
python -m unittest discover -s tests
python -m pip install -r requirements-build.txt
powershell -ExecutionPolicy Bypass -File scripts\build_exe.ps1
```
`requirements.txt` 只锁定运行所需第三方依赖;打包环境使用 `requirements-build.txt` 安装 PyInstaller;T-538 后 `data/` 统一保存配置、SQLite、图片、登录态、日志、提示词和密钥,运营 Excel 仍是本地数据,不提交版本库。
`requirements.txt` 只锁定运行所需第三方依赖;`requirements-dev.txt` 锁定 ruff 等开发检查依赖;打包环境使用 `requirements-build.txt` 安装 PyInstaller;T-538 后 `data/` 统一保存配置、SQLite、图片、登录态、日志、提示词和密钥,运营 Excel 仍是本地数据,不提交版本库。
GitHub Actions 工作流见 `.github/workflows/tests.yml`,在 push / pull_request 上使用 Windows + Python 3.11 安装 `requirements.txt`,并自动运行语法检查和全量单元/GUI 测试。
GitHub Actions 工作流见 `.github/workflows/tests.yml`,在 push / pull_request 上使用 Windows + Python 3.11 安装 `requirements.txt` 与 `requirements-dev.txt`,并自动运行 ruff、语法检查和全量单元/GUI 测试。
## 任务 / 进度 / 当前状态