docs: 修订宪章至 v2.2.0(新增文档规范原则)
新增 Principle VII: Documentation Standards(文档规范)
主要变更:
- 规定功能总结文档必须放在 docs/{feature-id}/ 目录,对应 specs/{feature-id}/
- 要求总结文档使用中文命名(功能总结.md、使用指南.md、架构说明.md)
- 要求总结文档内容使用中文编写,方便中文团队阅读
- 强制要求每次完成功能后更新 README.md,添加 2-3 句简短描述
- 目标:让首次接触项目的开发者能快速了解功能
模板同步更新:
- plan-template.md: 添加文档结构说明和 Documentation Standards 检查项
- tasks-template.md: 新增文档任务模板和文档相关质量检查项
版本升级理由:
MINOR 版本升级(2.1.1 → 2.2.0),因为新增了影响开发工作流程的强制性原则,
要求所有功能完成后必须创建中文总结文档并更新 README.md
This commit is contained in:
@@ -59,6 +59,13 @@
|
||||
- [ ] Code formatted with `gofmt`
|
||||
- [ ] Follows Effective Go and Go Code Review Comments
|
||||
|
||||
**Documentation Standards** (Constitution Principle VII):
|
||||
- [ ] Feature summary docs placed in `docs/{feature-id}/` mirroring `specs/{feature-id}/`
|
||||
- [ ] Summary doc filenames use Chinese (功能总结.md, 使用指南.md, etc.)
|
||||
- [ ] Summary doc content uses Chinese
|
||||
- [ ] README.md updated with brief Chinese summary (2-3 sentences)
|
||||
- [ ] Documentation is concise for first-time contributors
|
||||
|
||||
**Go Idiomatic Design**:
|
||||
- [ ] Package structure is flat (max 2-3 levels), organized by feature
|
||||
- [ ] Interfaces are small (1-3 methods), defined at use site
|
||||
@@ -105,6 +112,7 @@
|
||||
|
||||
### Documentation (this feature)
|
||||
|
||||
**设计文档(specs/ 目录)**:开发前的规划和设计
|
||||
```text
|
||||
specs/[###-feature]/
|
||||
├── plan.md # This file (/speckit.plan command output)
|
||||
@@ -115,6 +123,16 @@ specs/[###-feature]/
|
||||
└── tasks.md # Phase 2 output (/speckit.tasks command - NOT created by /speckit.plan)
|
||||
```
|
||||
|
||||
**总结文档(docs/ 目录)**:开发完成后的总结和使用指南(遵循 Constitution Principle VII)
|
||||
```text
|
||||
docs/[###-feature]/
|
||||
├── 功能总结.md # 功能概述、核心实现、技术要点(MUST 使用中文命名和内容)
|
||||
├── 使用指南.md # 如何使用该功能的详细说明(MUST 使用中文命名和内容)
|
||||
└── 架构说明.md # 架构设计和技术决策(可选,MUST 使用中文命名和内容)
|
||||
```
|
||||
|
||||
**README.md 更新**:每次完成功能后 MUST 在 README.md 添加简短描述(2-3 句话,中文)
|
||||
|
||||
### Source Code (repository root)
|
||||
<!--
|
||||
ACTION REQUIRED: Replace the placeholder tree below with the concrete layout
|
||||
|
||||
Reference in New Issue
Block a user