Repository navigation
Expand file tree
/
Copy pathmise.toml
More file actions
103 lines (77 loc) · 3.22 KB
/
Copy pathmise.toml
File metadata and controls
103 lines (77 loc) · 3.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
# mise 统一管理「运行时 + 命令入口」
# 运行时:mise install 按下面固定版本装好 python / uv
# 入口: mise run <task>,不再依赖 npm scripts
[tools]
python = "3.13"
uv = "latest"
[env]
# 统一 UTF-8 输出,避免日志/管道里中文乱码
PYTHONUTF8 = "1"
# 国内网络:uv 直连 pypi.org 实测超时,走清华镜像。
# 换回官方源就把下面这行删掉(或改成 https://pypi.org/simple)
UV_DEFAULT_INDEX = "https://pypi.tuna.tsinghua.edu.cn/simple"
# ---------- 环境 ----------
[tasks.setup]
description = "创建 .venv 并安装当前脚本所需依赖(= uv sync --extra ld)"
run = "uv sync --extra ld"
# ---------- 雷电模拟器(tools/ld_emulator) ----------
[tasks."ld:create"]
description = "批量创建模拟器:创建 → 配置 → 启动 → 装包 → 同步 → 权限"
run = "uv run --extra ld python -m tools.ld_emulator create"
[tasks."ld:start"]
description = "启动已存在的模拟器(按 ID 范围)"
run = "uv run --extra ld python -m tools.ld_emulator start"
[tasks."ld:create-txt"]
description = "按配置生成 cache.txt"
run = "uv run --extra ld python -m tools.ld_emulator create_txt"
[tasks."ld:backup"]
description = "按 ID 范围备份模拟器"
run = "uv run --extra ld python -m tools.ld_emulator backup"
[tasks."ld:restore"]
description = "按 ID 范围还原模拟器"
run = "uv run --extra ld python -m tools.ld_emulator restore"
[tasks."ld:check"]
description = "自检:加载依赖与配置,不做任何鼠标点击"
run = "uv run --extra ld python -m tools.ld_emulator default"
[tasks."ld:info"]
description = "列出全部模拟器实例(index/状态/分辨率/标题,只读)"
run = "uv run --extra ld python -m tools.ld_emulator info"
[tasks."ld:quit-all"]
description = "关闭全部模拟器(ldconsole quitall)"
run = "uv run --extra ld python -m tools.ld_emulator quitall"
[tasks."ld:gui"]
description = "强制走旧 GUI 流程(回滚用),默认 create_con"
run = "uv run --extra ld python -m tools.ld_emulator create_con --backend gui"
# ---------- WorkBuddy 积分签到(tools/wb_reward) ----------
[tasks."wb:all"]
description = "签到 + 旅行(默认动作)"
run = "uv run python -m tools.wb_reward all"
[tasks."wb:checkin"]
description = "只执行签到"
run = "uv run python -m tools.wb_reward checkin"
[tasks."wb:travel"]
description = "只执行旅行计划"
run = "uv run python -m tools.wb_reward travel"
[tasks."wb:growth"]
description = "成长计划:有可领档位才领取"
run = "uv run python -m tools.wb_reward growth auto"
[tasks."wb:health"]
description = "登录态健康检查(token 有效期 + 只读探活)"
run = "uv run python -m tools.wb_reward health"
[tasks."wb:status"]
description = "只读探活"
run = "uv run python -m tools.wb_reward status"
# ---------- 质量 ----------
[tasks.dev]
description = "安装开发依赖(pytest / ruff)"
run = "uv sync --extra ld --extra dev"
[tasks.lint]
description = "静态检查"
run = "uv run --extra dev ruff check kit tools"
[tasks.test]
description = "跑 pytest"
run = "uv run --extra dev --extra ld pytest -q"
# ---------- 发布 ----------
[tasks.release]
description = "提交并推送到 gitee / github"
run = "sh script/release.sh"