sdd-skills 1.1.7 → 1.1.9

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.
package/install.js CHANGED
@@ -72,10 +72,21 @@ async function promptInstallation() {
72
72
  // Removed default to force user selection
73
73
  },
74
74
  {
75
- type: 'confirm',
75
+ type: 'input',
76
76
  name: 'configureDingTalk',
77
- message: 'Would you like to configure DingTalk notifications?',
78
- default: false,
77
+ message: 'Would you like to configure DingTalk notifications? (y/n)',
78
+ default: 'n',
79
+ validate: (input) => {
80
+ const normalized = input.toLowerCase().trim();
81
+ if (['y', 'n', 'yes', 'no', ''].includes(normalized)) {
82
+ return true;
83
+ }
84
+ return 'Please enter y or n';
85
+ },
86
+ filter: (input) => {
87
+ const normalized = input.toLowerCase().trim();
88
+ return normalized === 'y' || normalized === 'yes';
89
+ },
79
90
  },
80
91
  ]);
81
92
 
@@ -243,10 +254,21 @@ async function install() {
243
254
 
244
255
  const { confirmInstall } = await inquirer.prompt([
245
256
  {
246
- type: 'confirm',
257
+ type: 'input',
247
258
  name: 'confirmInstall',
248
- message: 'Proceed with installation?',
249
- default: true,
259
+ message: 'Proceed with installation? (y/n)',
260
+ default: 'y',
261
+ validate: (input) => {
262
+ const normalized = input.toLowerCase().trim();
263
+ if (['y', 'n', 'yes', 'no', ''].includes(normalized)) {
264
+ return true;
265
+ }
266
+ return 'Please enter y or n';
267
+ },
268
+ filter: (input) => {
269
+ const normalized = input.toLowerCase().trim();
270
+ return normalized === '' || normalized === 'y' || normalized === 'yes';
271
+ },
250
272
  },
251
273
  ]);
252
274
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sdd-skills",
3
- "version": "1.1.7",
3
+ "version": "1.1.9",
4
4
  "description": "Spec-Driven Development Skills for Claude Code - SAE/ADE workflow automation",
5
5
  "type": "module",
6
6
  "main": "install.js",
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: code-reviewer
3
- description: 代码审查专家,负责代码质量、安全审查和规范检查。当测试通过需要代码审查时激活。检查代码风格、最佳实践、安全漏洞、性能问题,审查不通过时触发钉钉通知。
3
+ description: 代码审查专家,负责代码质量、安全审查和规范检查。当代码实现完成需要代码审查时激活。检查代码风格、最佳实践、安全漏洞、性能问题,审查不通过时触发钉钉通知。
4
4
  ---
5
5
 
6
6
  # Code Reviewer
@@ -211,7 +211,7 @@ const HeavyComponent = defineAsyncComponent(() =>
211
211
  - [ ] 避免魔法数字,使用常量
212
212
  - [ ] 避免重复代码(DRY 原则)
213
213
  - [ ] 复杂逻辑有注释说明
214
- - [ ] 测试覆盖率达标(后端 >= 90%, 前端 >= 70%)
214
+ - [ ] 测试覆盖率达标(后端 >= 90%, 前端 >= 90%)
215
215
 
216
216
  ```go
217
217
  // ❌ 可维护性问题:魔法数字
@@ -391,7 +391,7 @@ npm audit
391
391
  - [ ] Pinia store 设计合理
392
392
  - [ ] 类型定义完整
393
393
  - [ ] 复杂逻辑有注释
394
- - [ ] 测试覆盖率 >= 70%
394
+ - [ ] 测试覆盖率 >= 90%
395
395
  ```
396
396
 
397
397
  ## 钉钉通知集成
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: git-engineer
3
- description: Git工程师,负责代码提交、版本管理和MR创建。当代码审查通过需要提交代码时激活。执行预检测(lint/build/test)、规范化提交、创建GitLab MR,失败时触发钉钉通知。
3
+ description: Git工程师,负责代码提交、版本管理和MR创建。当测试通过需要提交代码时激活。执行预检测(lint/build/test)、规范化提交、创建GitLab MR,失败时触发钉钉通知。
4
4
  ---
5
5
 
6
6
  # Git Engineer
@@ -56,7 +56,7 @@ npm run test:unit
56
56
 
57
57
  # 6. 检查覆盖率
58
58
  npm run test:coverage
59
- # 要求: >= 70%
59
+ # 要求: >= 90%
60
60
  ```
61
61
 
62
62
  ✅ **预检测通过标准**:
@@ -202,7 +202,7 @@ glab mr create \
202
202
 
203
203
  ## 测试结果
204
204
  - 后端覆盖率:92% (>= 90%)
205
- - 前端覆盖率:75% (>= 70%)
205
+ - 前端覆盖率:92% (>= 90%)
206
206
  - E2E 测试:3/3 通过
207
207
 
208
208
  ## 验收标准
@@ -244,7 +244,7 @@ glab mr create
244
244
 
245
245
  ## 测试结果
246
246
  - 后端覆盖率:XX% (>= 90%)
247
- - 前端覆盖率:XX% (>= 70%)
247
+ - 前端覆盖率:XX% (>= 90%)
248
248
  - E2E 测试:X/X 通过
249
249
 
250
250
  ## 验收标准
@@ -475,7 +475,7 @@ glab mr status
475
475
  ✅ 类型检查:通过
476
476
  ✅ 编译检查:通过
477
477
  ✅ 单元测试:8/8 通过
478
- ✅ 覆盖率:75% (>= 70%)
478
+ ✅ 覆盖率:92% (>= 90%)
479
479
 
480
480
  ✅ 所有预检测通过!
481
481
 
@@ -185,7 +185,7 @@ Response (401):
185
185
  ## 决策原则
186
186
 
187
187
  遵循以下技术决策优先级:
188
- 1. **稳定性 > 性能 > 安全性 > 成本**
188
+ 1. **安全性 > 稳定性 > 性能 > 成本**
189
189
  2. **技术选型标准**:
190
190
  - 成熟度高,社区活跃
191
191
  - 团队熟悉程度
package/uninstall.js CHANGED
@@ -90,26 +90,48 @@ async function promptUninstallation() {
90
90
  choices: locationChoices,
91
91
  },
92
92
  {
93
- type: 'confirm',
93
+ type: 'input',
94
94
  name: 'removeConfig',
95
- message: 'Also remove DingTalk configuration?',
96
- default: true,
95
+ message: 'Also remove DingTalk configuration? (y/n)',
96
+ default: 'y',
97
97
  when: (answers) => {
98
98
  const configPath = answers.location === 'global' ? GLOBAL_CONFIG : LOCAL_CONFIG;
99
99
  return existsSync(configPath);
100
100
  },
101
+ validate: (input) => {
102
+ const normalized = input.toLowerCase().trim();
103
+ if (['y', 'n', 'yes', 'no', ''].includes(normalized)) {
104
+ return true;
105
+ }
106
+ return 'Please enter y or n';
107
+ },
108
+ filter: (input) => {
109
+ const normalized = input.toLowerCase().trim();
110
+ return normalized === '' || normalized === 'y' || normalized === 'yes';
111
+ },
101
112
  },
102
113
  {
103
- type: 'confirm',
114
+ type: 'input',
104
115
  name: 'confirm',
105
116
  message: (answers) => {
106
117
  const location = answers.location;
107
118
  const skillsCount = location === 'global'
108
119
  ? globalInstallation.skills.length
109
120
  : localInstallation.skills.length;
110
- return `${chalk.red('Are you sure you want to remove')} ${chalk.bold.red(skillsCount)} ${chalk.red('Skills?')}`;
121
+ return `${chalk.red('Are you sure you want to remove')} ${chalk.bold.red(skillsCount)} ${chalk.red('Skills?')} (y/n)`;
122
+ },
123
+ default: 'n',
124
+ validate: (input) => {
125
+ const normalized = input.toLowerCase().trim();
126
+ if (['y', 'n', 'yes', 'no', ''].includes(normalized)) {
127
+ return true;
128
+ }
129
+ return 'Please enter y or n';
130
+ },
131
+ filter: (input) => {
132
+ const normalized = input.toLowerCase().trim();
133
+ return normalized === 'y' || normalized === 'yes';
111
134
  },
112
- default: false,
113
135
  },
114
136
  ]);
115
137