Files
STM32F4-Base/scripts/rename_maps/batch2.json
T
wandering1 ad87f979b1 docs(规约): 删除编号规范.md,生效规则并入文档规范 §7.1
用户裁定:docs/编号规范.md 在项目里已无意义,删除。

依据:该文 253 行里真正仍生效的只有两条规则(新条目一律不发编号、
人读文档存量编号继续清退)和一张存量族表;其余内容早有归属——两道
编号门禁的退役记录在 docs/门禁说明/id-check.md 与 id-check-new.md,
手工普查与恢复机器面在 scripts/archive/id_gate/README.md。留着就是
第二真相源,同一事实写在两处迟早漂移。

处理:
- docs/文档规范.md 新增 §7.1「条目与编号:一律不发」,承接规则、
  场景表、三条硬规矩、存量族表、已停发旧号族清单、不是编号的清单、
  清理动作与「没有机器门禁兜底」四段。
- 活跃引用 62 处逐条改指 §7.1 或归档 README:AGENTS.md 2 处、
  门禁说明三篇 18 处、其余文档 11 篇、代码与脚本 10 处、rename_maps
  七个 record 字段、.dsh/skills 四个文件 8 处。
- 归档区 107 处去掉 docs/ 前缀当纯文本提及;编号治理历史.md 45 处
  改为「原编号规范 §N」,避免被 doc-links 当自引用解析。
- 顺带修正 scripts/archive/id_gate/README.md 里仍称旧文为现行规范
  的表述。

门禁:check_doc_links --all --sections-strict 220 篇全通过、无法判定 0;
pre-commit 全 Passed。
2026-11-06 18:32:04 +08:00

26 lines
4.9 KiB
JSON
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{
"schema": 1,
"batch": "批 2(模块码单词化,16 个有歧义的码)",
"applied_by": "scripts/rename_ids.py",
"record": "当时的编号规范 §6 模块码表 + §8.3 迁移批次记录",
"note": "字面量已完全限定(TC-<旧码>-<nnn>),故别名全局生效;裸形族才需要 scope",
"batches": [
{"family": "TC-ADCIN", "old": "\\bTC-AI-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-ADCIN-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 AI → ADCIN(App/algo/adc_input;与 AH 只差一个字母)"},
{"family": "TC-ADCHEALTH", "old": "\\bTC-AH-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-ADCHEALTH-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 AH → ADCHEALTH(App/algo/adc_health)"},
{"family": "TC-PROTSET", "old": "\\bTC-PS-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-PROTSET-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 PS → PROTSET(App/algo/prot_set 保护定值)"},
{"family": "TC-PROTELEM", "old": "\\bTC-PE-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-PROTELEM-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 PE → PROTELEM(App/algo/prot_elm 保护元件/判据)"},
{"family": "TC-PHASOR", "old": "\\bTC-PH-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-PHASOR-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 PH → PHASOR(App/algo/phasor + sample_ring)"},
{"family": "TC-TIMESYNC", "old": "\\bTC-TS-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-TIMESYNC-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 TS → TIMESYNC(App/sync/time_sync;TS 与 test suite / 时间戳 撞义)"},
{"family": "TC-VOLLOCK", "old": "\\bTC-VL-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-VOLLOCK-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 VL → VOLLOCK(App/fs/vol_lock 卷锁)"},
{"family": "TC-NANDPORT", "old": "\\bTC-NP-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-NANDPORT-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 NP → NANDPORT(dhara NAND 移植层;原名看不出是移植层)"},
{"family": "TC-CONFIG", "old": "\\bTC-CFG-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-CONFIG-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 CFG → CONFIG(App/cfg + Drivers/BSP/NETCFG)"},
{"family": "TC-SYSCLK", "old": "\\bTC-CLK-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-SYSCLK-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 CLK → SYSCLK(App/util/sys_clock;CLK 也泛指任何时钟信号)"},
{"family": "TC-WATCHDOG", "old": "\\bTC-WD-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-WATCHDOG-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 WD → WATCHDOG(App/util/task_watchdog;WD 也读作『喂狗动作』)"},
{"family": "TC-STORAGE", "old": "\\bTC-STO-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-STORAGE-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 STO → STORAGE(存储栈 FTL+FatFs+App/fs;STO 易读成 stop)"},
{"family": "TC-SHA256", "old": "\\bTC-SH-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-SHA256-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 SH → SHA256(App/util/sha256;算法名应写全)"},
{"family": "TC-FTPAUTH", "old": "\\bTC-FA-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-FTPAUTH-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 FA → FTPAUTH(Drivers/BSP/NET/lftpd 鉴权)"},
{"family": "TC-FREQ", "old": "\\bTC-FR-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-FREQ-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:模块码 FR → FREQ(App/algo/freq L2.5 测频)"},
{"family": "TC-IEC104", "old": "\\bTC-104-(?P<n>[0-9]{1,4}[a-zA-Z]?)\\b", "new": "TC-IEC104-{n}", "global_alias": true, "files": ["*", "*/*", "*/*/*", "*/*/*/*", "*/*/*/*/*", "*/*/*/*/*/*"], "note": "批 2:数字模块码 104 → IEC104(§6 表里本就写 I104,代码写成纯数字 104;纯数字不是模块码)"}
]
}