style(docs): standardize heading formats and numbering

- Enforce Level 1-3 structural numbering based on SUMMARY.md hierarchy
- Remove structural numbering from Level 4+ headings
- Eliminate single child headings by converting to bold text
- Auto-inject summary text for headings with multiple children missing intro text
- Exclude Appendix chapters from structural numbering
- Avoid modifying code block contents
- Add script to detect non-standard English usage in headers
This commit is contained in:
Baohua Yang
2026-02-21 22:40:33 -08:00
parent 33af380be1
commit 175aaae48a
136 changed files with 1015 additions and 766 deletions

View File

@@ -2,7 +2,7 @@
本节涵盖了相关内容与详细描述主要探讨以下几个方面
### 基本语法
### 7.10.1 基本语法
如下代码块所示展示了相关示例
@@ -14,7 +14,7 @@ WORKDIR <工作目录路径>
---
### 基本用法
### 7.10.2 基本用法
如下代码块所示展示了相关示例
@@ -28,7 +28,7 @@ COPY . . # 复制到 /app/
---
### 为什么需要 WORKDIR
### 7.10.3 为什么需要 WORKDIR
本节涵盖了相关内容与详细描述主要探讨以下几个方面
@@ -73,7 +73,7 @@ RUN echo "hello" > world.txt # 创建 /app/world.txt
---
### 相对路径
### 7.10.4 相对路径
WORKDIR 支持相对路径基于上一个 WORKDIR
@@ -87,7 +87,7 @@ RUN pwd # 输出 /a/b/c
---
### 使用环境变量
### 7.10.5 使用环境变量
如下代码块所示展示了相关示例
@@ -100,7 +100,7 @@ RUN pwd # 输出 /app
---
### 多阶段构建中的 WORKDIR
### 7.10.6 多阶段构建中的 WORKDIR
如下代码块所示展示了相关示例
@@ -123,7 +123,7 @@ COPY --from=builder /build/dist .
---
### 最佳实践
### 7.10.7 最佳实践
本节涵盖了相关内容与详细描述主要探讨以下几个方面
@@ -186,7 +186,7 @@ WORKDIR /data
---
### 与其他指令的关系
### 7.10.8 与其他指令的关系
相关信息如下表
@@ -208,7 +208,7 @@ CMD ["./start.sh"] # /app/start.sh
---
### 运行时覆盖
### 7.10.9 运行时覆盖
使用 `-w` 参数覆盖工作目录