@superspec/cli 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. package/dist/cli/index.js +1329 -0
  2. package/dist/cli/index.js.map +1 -0
  3. package/dist/index.d.ts +52 -0
  4. package/dist/index.js +607 -0
  5. package/dist/index.js.map +1 -0
  6. package/package.json +63 -0
  7. package/prompts/agents.md +150 -0
  8. package/prompts/cursor-rules.md +154 -0
  9. package/templates/en/checklist.md +62 -0
  10. package/templates/en/clarify.md +44 -0
  11. package/templates/en/commands/ss-apply.md +19 -0
  12. package/templates/en/commands/ss-archive.md +15 -0
  13. package/templates/en/commands/ss-checklist.md +16 -0
  14. package/templates/en/commands/ss-clarify.md +17 -0
  15. package/templates/en/commands/ss-create.md +19 -0
  16. package/templates/en/commands/ss-deps.md +11 -0
  17. package/templates/en/commands/ss-link.md +11 -0
  18. package/templates/en/commands/ss-lint.md +15 -0
  19. package/templates/en/commands/ss-resume.md +17 -0
  20. package/templates/en/commands/ss-search.md +12 -0
  21. package/templates/en/commands/ss-status.md +12 -0
  22. package/templates/en/commands/ss-tasks.md +19 -0
  23. package/templates/en/commands/ss-validate.md +15 -0
  24. package/templates/en/proposal.md +53 -0
  25. package/templates/en/spec.md +73 -0
  26. package/templates/en/tasks.md +52 -0
  27. package/templates/zh/checklist.md +62 -0
  28. package/templates/zh/clarify.md +44 -0
  29. package/templates/zh/commands/ss-apply.md +19 -0
  30. package/templates/zh/commands/ss-archive.md +15 -0
  31. package/templates/zh/commands/ss-checklist.md +16 -0
  32. package/templates/zh/commands/ss-clarify.md +17 -0
  33. package/templates/zh/commands/ss-create.md +19 -0
  34. package/templates/zh/commands/ss-deps.md +11 -0
  35. package/templates/zh/commands/ss-link.md +11 -0
  36. package/templates/zh/commands/ss-lint.md +15 -0
  37. package/templates/zh/commands/ss-resume.md +17 -0
  38. package/templates/zh/commands/ss-search.md +12 -0
  39. package/templates/zh/commands/ss-status.md +12 -0
  40. package/templates/zh/commands/ss-tasks.md +19 -0
  41. package/templates/zh/commands/ss-validate.md +15 -0
  42. package/templates/zh/proposal.md +59 -0
  43. package/templates/zh/spec.md +73 -0
  44. package/templates/zh/tasks.md +52 -0
@@ -0,0 +1,19 @@
1
+ ---
2
+ name: /ss-tasks
3
+ id: ss-tasks
4
+ category: SuperSpec
5
+ description: 从 proposal 生成任务清单
6
+ ---
7
+ <!-- SUPERSPEC:START -->
8
+ **Guardrails**
9
+ - 首先读取 proposal.md(boost 模式下还要读取 spec.md)
10
+ - 任务必须小而可验证,可执行(boost 模式下每个任务 < 1 小时)
11
+ - 将同一文件的相关变更归为一个任务
12
+ - 每个任务包含验证步骤
13
+
14
+ **Steps**
15
+ 1. 读取 `{specDir}/changes/<name>/proposal.md`
16
+ 2. 如果是 boost 模式,同时读取 `spec.md`
17
+ 3. 生成 tasks.md,包含分阶段的实现步骤
18
+ 4. 每个任务应包含:清晰描述、文件路径、依赖关系、验证标准
19
+ <!-- SUPERSPEC:END -->
@@ -0,0 +1,15 @@
1
+ ---
2
+ name: /ss-validate
3
+ id: ss-validate
4
+ category: SuperSpec
5
+ description: 交叉引用一致性检查(boost 模式)
6
+ ---
7
+ <!-- SUPERSPEC:START -->
8
+ **Guardrails**
9
+ - 验证 US↔FR↔AC↔tasks 一致性
10
+ - 仅在 boost 模式下适用
11
+
12
+ **Steps**
13
+ 1. 运行 `superspec validate [name]`
14
+ 2. 修复报告的任何一致性错误
15
+ <!-- SUPERSPEC:END -->
@@ -0,0 +1,59 @@
1
+ ---
2
+ name: {{name}}
3
+ status: draft
4
+ strategy: {{strategy}}
5
+ depends_on: []
6
+ ---
7
+
8
+ # 提案: {{name}}
9
+
10
+ > 创建日期: {{date}}
11
+ {{#if description}}
12
+ > 描述: {{description}}
13
+ {{/if}}
14
+
15
+ ## 背景
16
+
17
+ <!-- 为什么要做这个变更?当前存在什么问题? -->
18
+ {{#if description}}
19
+ <!-- 初始描述: {{description}} -->
20
+ {{/if}}
21
+
22
+ ## 目标
23
+
24
+ <!-- 这个变更要达成什么目标? -->
25
+
26
+ - [ ] 目标 1
27
+ - [ ] 目标 2
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
+ 1.
56
+
57
+ ---
58
+
59
+ **状态**: 🟡 草稿
@@ -0,0 +1,73 @@
1
+ ---
2
+ name: {{name}}
3
+ status: draft
4
+ strategy: {{strategy}}
5
+ depends_on: []
6
+ ---
7
+
8
+ # 规格说明: {{name}}
9
+
10
+ > 创建日期: {{date}}
11
+
12
+ ## 概述
13
+
14
+ <!-- 对本次变更的简要描述 -->
15
+
16
+ ## 用户故事
17
+
18
+ ### US-1: [故事标题]
19
+
20
+ **作为** [角色],**我想要** [功能],**以便** [价值]
21
+
22
+ #### 验收标准
23
+
24
+ - [ ] AC-1.1:
25
+ - [ ] AC-1.2:
26
+
27
+ ### US-2: [故事标题]
28
+
29
+ **作为** [角色],**我想要** [功能],**以便** [价值]
30
+
31
+ #### 验收标准
32
+
33
+ - [ ] AC-2.1:
34
+ - [ ] AC-2.2:
35
+
36
+ ## 功能需求
37
+
38
+ ### FR-1: [需求标题]
39
+
40
+ - **描述**:
41
+ - **优先级**: P0 / P1 / P2
42
+ - **依赖**:
43
+
44
+ ### FR-2: [需求标题]
45
+
46
+ - **描述**:
47
+ - **优先级**: P0 / P1 / P2
48
+ - **依赖**:
49
+
50
+ ## 非功能需求
51
+
52
+ - **性能**:
53
+ - **安全性**:
54
+ - **兼容性**:
55
+
56
+ ## 数据模型
57
+
58
+ <!-- 如有需要,描述数据结构变更 -->
59
+
60
+ ## API 设计
61
+
62
+ <!-- 如有需要,描述接口设计 -->
63
+
64
+ ## 边界情况
65
+
66
+ <!-- 需要考虑的边界场景 -->
67
+
68
+ 1.
69
+ 2.
70
+
71
+ ---
72
+
73
+ **状态**: 🟡 草稿
@@ -0,0 +1,52 @@
1
+ ---
2
+ name: {{name}}
3
+ status: draft
4
+ strategy: {{strategy}}
5
+ depends_on: []
6
+ ---
7
+
8
+ # 任务清单: {{name}}
9
+
10
+ > 创建日期: {{date}}
11
+
12
+ ## 阶段 1: 基础设施
13
+
14
+ - [ ] 1.1 [任务描述]
15
+ - 文件: `path/to/file`
16
+ - 依赖: 无
17
+ - [ ] 1.2 [任务描述]
18
+ - 文件: `path/to/file`
19
+ - 依赖: 1.1
20
+
21
+ ## 阶段 2: 核心实现
22
+
23
+ - [ ] 2.1 [任务描述]
24
+ - 文件: `path/to/file`
25
+ - 依赖: 阶段 1
26
+ - [ ] 2.2 [任务描述] `[P]`
27
+ - 文件: `path/to/file`
28
+ - 依赖: 2.1
29
+ - [ ] 2.3 [任务描述] `[P]`
30
+ - 文件: `path/to/file`
31
+ - 依赖: 2.1
32
+
33
+ ## 阶段 3: 集成与验证
34
+
35
+ - [ ] 3.1 [任务描述]
36
+ - 文件: `path/to/file`
37
+ - 依赖: 阶段 2
38
+ - [ ] 3.2 [任务描述]
39
+ - 文件: `path/to/file`
40
+ - 依赖: 3.1
41
+
42
+ ## 检查点
43
+
44
+ - [ ] 阶段 1 完成,基础可用
45
+ - [ ] 阶段 2 完成,核心功能就绪
46
+ - [ ] 阶段 3 完成,集成验证通过
47
+
48
+ ---
49
+
50
+ `[P]` = 可并行执行
51
+
52
+ **状态**: 🟡 待实现