docs: 清除文档中的真实部署信息与易混淆 Unicode 字符
需求:公开仓库的说明文档不应暴露开发/部署期信息,且 Gitea 会对 README.txt 报"含模棱两可的 Unicode 字符"。 敏感信息(全部替换为占位符或文档示例值): - 真实数据库实例:DB_HOST=192.168.150.10 / DB_USER=dpendance / DB_NAME=dpendance → <数据库主机> / opendance_app / opendance(web-server/.env.example、 deploy/.env.example、contracts/database.md ×3 库、project.yaml、README.txt 的建库 SQL、tasks/001、tasks/002) - 内网网段 192.168.150.0/24 / 192.168.150.20 / 192.168.1.10 → RFC 5737 文档网段 192.0.2.0/24 等(含测试夹具,行为不变) - 真实 Gitea 域名 → https://<Gitea 地址>/<owner>/<repo>(systemd 单元、 Windows/Android README 的交叉链接) - 测试夹具里的真实口令字面量 → 虚构口令(仍覆盖特殊字符场景) - 保留 /opt/opendance、/var/lib/opendance 等产品默认安装路径(非敏感) README.txt 易混淆字符: - 全角拉丁字母(I/K 等)与全角 ASCII 标点((),:;?)→ 半角 + 中文排版空格 - 正文里的乱码字节样例(模å…)→ 改为文字描述 - × → x,★ → * - 注意:代码/测试/契约里的全角「IK」是 MMD 真实骨骼名,**必须保留**, 已回滚误改(mmd-skeleton.ts、mmd-vmd.spec.ts、inspect-vmd.mjs、各契约) 验证:168 项单测通过(含 VMD 31 项,确认全角骨骼名未被破坏)。
This commit is contained in:
@@ -28,9 +28,9 @@ describe('启动日志的访问地址推导', () => {
|
||||
});
|
||||
|
||||
it('绑定具体网卡时只给该地址,并提示范围', () => {
|
||||
const { listen, urls } = describeAccess('192.168.150.20', 8080);
|
||||
expect(listen).toBe('192.168.150.20:8080(仅该地址可访问)');
|
||||
expect(urls).toEqual(['http://192.168.150.20:8080']);
|
||||
const { listen, urls } = describeAccess('192.0.2.20', 8080);
|
||||
expect(listen).toBe('192.0.2.20:8080(仅该地址可访问)');
|
||||
expect(urls).toEqual(['http://192.0.2.20:8080']);
|
||||
});
|
||||
|
||||
it('端口号被完整带进每个地址', () => {
|
||||
@@ -102,10 +102,10 @@ describe('双端口访问提示', () => {
|
||||
expect(
|
||||
preferredUrl({
|
||||
listen: '',
|
||||
urls: ['http://127.0.0.1:3000', 'http://192.168.1.10:3000'],
|
||||
urls: ['http://127.0.0.1:3000', 'http://192.0.2.10:3000'],
|
||||
loopbackOnly: false,
|
||||
}),
|
||||
).toBe('http://192.168.1.10:3000');
|
||||
).toBe('http://192.0.2.10:3000');
|
||||
expect(
|
||||
preferredUrl({ listen: '', urls: ['http://127.0.0.1:3000'], loopbackOnly: true }),
|
||||
).toBe('http://127.0.0.1:3000');
|
||||
|
||||
Reference in New Issue
Block a user