universal-dev-standards 3.5.1-beta.16 → 3.5.1-beta.17

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/bin/uds.js CHANGED
@@ -57,12 +57,14 @@ program
57
57
  .description('Modify options for initialized project')
58
58
  .option('-t, --type <type>', 'Option type to configure (format, workflow, merge_strategy, commit_language, test_levels, skills, commands, all)')
59
59
  .option('--ai-tool <tool>', 'Specific AI tool to configure (claude-code, opencode, copilot, etc.) - enables non-interactive mode')
60
+ .option('-y, --yes', 'Apply changes immediately without prompting')
60
61
  .option('-E, --experimental', 'Enable experimental features (methodology)')
61
62
  .action(configureCommand);
62
63
 
63
64
  program
64
65
  .command('check')
65
66
  .description('Check adoption status of current project')
67
+ .option('--summary', 'Show compact status summary (for use by other commands)')
66
68
  .option('--diff', 'Show diff for modified files')
67
69
  .option('--restore', 'Restore all modified and missing files')
68
70
  .option('--restore-missing', 'Restore only missing files')
@@ -2,8 +2,8 @@
2
2
 
3
3
  > **Language**: English | [繁體中文](../locales/zh-TW/core/checkin-standards.md)
4
4
 
5
- **Version**: 1.3.0
6
- **Last Updated**: 2026-01-05
5
+ **Version**: 1.4.0
6
+ **Last Updated**: 2026-01-16
7
7
  **Applicability**: All software projects using version control
8
8
 
9
9
  ---
@@ -90,6 +90,42 @@ pytest --cov=src tests/
90
90
  - Review test coverage report
91
91
  - Ensure new code paths are tested
92
92
 
93
+ #### Bug Fix Testing Evaluation
94
+
95
+ When fixing bugs, evaluate whether to add regression tests:
96
+
97
+ **✅ MUST Add Tests (High Value)**:
98
+ | Condition | Reason |
99
+ |-----------|--------|
100
+ | Security-related bugs | Prevent recurrence of vulnerabilities |
101
+ | Data integrity bugs | Protect critical business data |
102
+ | Bugs that caused outages | Ensure system stability |
103
+ | Bugs that recurred | Break the cycle of repeated issues |
104
+ | Complex business logic bugs | Document expected behavior |
105
+
106
+ **⚠️ OPTIONAL Tests (Lower Value)**:
107
+ | Condition | Reason |
108
+ |-----------|--------|
109
+ | Simple typos | Low recurrence risk |
110
+ | Obvious logic errors (e.g., `>` vs `<`) | Easy to spot in review |
111
+ | Already covered by existing tests | Avoid redundant tests |
112
+ | One-time configuration errors | Won't recur in code |
113
+
114
+ **Quick Decision Questions**:
115
+ 1. Could this bug recur from future code changes? → YES = Add test
116
+ 2. Would existing tests have caught this bug? → NO = Add test
117
+ 3. Is this a critical path or core functionality? → YES = Add test
118
+ 4. Did this bug occur before? → YES = Add test
119
+
120
+ **Regression Test Naming**:
121
+ ```javascript
122
+ describe('Regression: [BUG-ID or description]', () => {
123
+ it('should [correct behavior] when [trigger condition]', () => {
124
+ // Test that would have caught the bug
125
+ });
126
+ });
127
+ ```
128
+
93
129
  ---
94
130
 
95
131
  ### 3. Code Quality
@@ -901,6 +937,7 @@ git commit -m "feat(module-c): add export to CSV feature"
901
937
 
902
938
  | Version | Date | Changes |
903
939
  |---------|------|---------|
940
+ | 1.4.0 | 2026-01-16 | Added: Bug Fix Testing Evaluation section with decision matrix |
904
941
  | 1.3.0 | 2026-01-05 | Added: SWEBOK v4.0 Chapter 6 (Software Configuration Management) to References |
905
942
  | 1.2.5 | 2025-12-16 | Clarified: CHANGELOG update is for user-facing changes only, added to [Unreleased] section |
906
943
  | 1.2.4 | 2025-12-11 | Added: Pre-commit directory hygiene section (IDE artifacts, verification commands) |
@@ -1,8 +1,8 @@
1
1
  ---
2
2
  source: core/checkin-standards.md
3
- source_version: 1.3.0
4
- translation_version: 1.3.0
5
- last_synced: 2026-01-05
3
+ source_version: 1.4.0
4
+ translation_version: 1.4.0
5
+ last_synced: 2026-01-16
6
6
  status: current
7
7
  ---
8
8
 
@@ -10,8 +10,8 @@ status: current
10
10
 
11
11
  > **语言**: [English](../../../core/checkin-standards.md) | 繁体中文
12
12
 
13
- **版本**: 1.3.0
14
- **最后更新**: 2026-01-05
13
+ **版本**: 1.4.0
14
+ **最后更新**: 2026-01-16
15
15
  **适用范围**: 所有使用版本控制的软体专案
16
16
 
17
17
  ---
@@ -98,6 +98,42 @@ pytest --cov=src tests/
98
98
  - Review test coverage report
99
99
  - Ensure new code paths are tested
100
100
 
101
+ #### Bug 修复测试评估
102
+
103
+ 修复 bug 时,评估是否需要新增回归测试:
104
+
105
+ **✅ 必须加测试(高价值)**:
106
+ | 情况 | 原因 |
107
+ |------|------|
108
+ | 安全相关的 bug | 防止漏洞再次发生 |
109
+ | 数据完整性相关的 bug | 保护关键业务数据 |
110
+ | 造成服务中断的 bug | 确保系统稳定性 |
111
+ | 曾经重复出现的 bug | 打破重复出现的循环 |
112
+ | 复杂业务逻辑的 bug | 记录预期行为 |
113
+
114
+ **⚠️ 测试为可选(低价值)**:
115
+ | 情况 | 原因 |
116
+ |------|------|
117
+ | 单纯的 typo 修正 | 再发风险低 |
118
+ | 显而易见的逻辑错误(如 `>` 写成 `<`) | 审查时容易发现 |
119
+ | 已被现有测试覆盖 | 避免重复测试 |
120
+ | 一次性的配置错误 | 不会在程序码中再发生 |
121
+
122
+ **快速决策问题**:
123
+ 1. 这个 bug 是否可能因未来的程序码变更而重现? → 是 = 加测试
124
+ 2. 现有的测试是否能捕捉到这个 bug? → 否 = 加测试
125
+ 3. 这是否影响核心功能或关键路径? → 是 = 加测试
126
+ 4. 这个 bug 曾经出现过吗? → 是 = 加测试
127
+
128
+ **回归测试命名**:
129
+ ```javascript
130
+ describe('Regression: [BUG-ID or description]', () => {
131
+ it('should [correct behavior] when [trigger condition]', () => {
132
+ // Test that would have caught the bug
133
+ });
134
+ });
135
+ ```
136
+
101
137
  ---
102
138
 
103
139
  ### 3. 程序码品质
@@ -909,6 +945,7 @@ git commit -m "feat(module-c): add export to CSV feature"
909
945
 
910
946
  | 版本 | 日期 | 变更 |
911
947
  |---------|------|---------|
948
+ | 1.4.0 | 2026-01-16 | 新增:Bug 修复测试评估章节与决策矩阵 |
912
949
  | 1.3.0 | 2026-01-05 | 新增:SWEBOK v4.0 第 6 章(软体配置管理)至参考资料 |
913
950
  | 1.2.5 | 2025-12-16 | Clarified: CHANGELOG update is for user-facing changes only, added to [Unreleased] section |
914
951
  | 1.2.4 | 2025-12-11 | Added: Pre-commit directory hygiene section (IDE artifacts, verification commands) |
@@ -1,8 +1,8 @@
1
1
  ---
2
2
  source: core/checkin-standards.md
3
- source_version: 1.3.0
4
- translation_version: 1.3.0
5
- last_synced: 2026-01-05
3
+ source_version: 1.4.0
4
+ translation_version: 1.4.0
5
+ last_synced: 2026-01-16
6
6
  status: current
7
7
  ---
8
8
 
@@ -10,8 +10,8 @@ status: current
10
10
 
11
11
  > **語言**: [English](../../../core/checkin-standards.md) | 繁體中文
12
12
 
13
- **版本**: 1.3.0
14
- **最後更新**: 2026-01-05
13
+ **版本**: 1.4.0
14
+ **最後更新**: 2026-01-16
15
15
  **適用範圍**: 所有使用版本控制的軟體專案
16
16
 
17
17
  ---
@@ -98,6 +98,42 @@ pytest --cov=src tests/
98
98
  - Review test coverage report
99
99
  - Ensure new code paths are tested
100
100
 
101
+ #### Bug 修復測試評估
102
+
103
+ 修復 bug 時,評估是否需要新增回歸測試:
104
+
105
+ **✅ 必須加測試(高價值)**:
106
+ | 情況 | 原因 |
107
+ |------|------|
108
+ | 安全相關的 bug | 防止漏洞再次發生 |
109
+ | 資料完整性相關的 bug | 保護關鍵業務資料 |
110
+ | 造成服務中斷的 bug | 確保系統穩定性 |
111
+ | 曾經重複出現的 bug | 打破重複出現的循環 |
112
+ | 複雜業務邏輯的 bug | 記錄預期行為 |
113
+
114
+ **⚠️ 測試為可選(低價值)**:
115
+ | 情況 | 原因 |
116
+ |------|------|
117
+ | 單純的 typo 修正 | 再發風險低 |
118
+ | 顯而易見的邏輯錯誤(如 `>` 寫成 `<`) | 審查時容易發現 |
119
+ | 已被現有測試覆蓋 | 避免重複測試 |
120
+ | 一次性的配置錯誤 | 不會在程式碼中再發生 |
121
+
122
+ **快速決策問題**:
123
+ 1. 這個 bug 是否可能因未來的程式碼變更而重現? → 是 = 加測試
124
+ 2. 現有的測試是否能捕捉到這個 bug? → 否 = 加測試
125
+ 3. 這是否影響核心功能或關鍵路徑? → 是 = 加測試
126
+ 4. 這個 bug 曾經出現過嗎? → 是 = 加測試
127
+
128
+ **回歸測試命名**:
129
+ ```javascript
130
+ describe('Regression: [BUG-ID or description]', () => {
131
+ it('should [correct behavior] when [trigger condition]', () => {
132
+ // Test that would have caught the bug
133
+ });
134
+ });
135
+ ```
136
+
101
137
  ---
102
138
 
103
139
  ### 3. 程式碼品質
@@ -909,6 +945,7 @@ git commit -m "feat(module-c): add export to CSV feature"
909
945
 
910
946
  | 版本 | 日期 | 變更 |
911
947
  |---------|------|---------|
948
+ | 1.4.0 | 2026-01-16 | 新增:Bug 修復測試評估章節與決策矩陣 |
912
949
  | 1.3.0 | 2026-01-05 | 新增:SWEBOK v4.0 第 6 章(軟體配置管理)至參考資料 |
913
950
  | 1.2.5 | 2025-12-16 | Clarified: CHANGELOG update is for user-facing changes only, added to [Unreleased] section |
914
951
  | 1.2.4 | 2025-12-11 | Added: Pre-commit directory hygiene section (IDE artifacts, verification commands) |
@@ -27,6 +27,7 @@ uds check --restore
27
27
 
28
28
  | Option | Description | 說明 |
29
29
  |--------|-------------|------|
30
+ | `--summary` | Show compact status summary | 顯示精簡狀態摘要 |
30
31
  | `--offline` | Skip npm registry check | 跳過 npm registry 檢查 |
31
32
  | `--diff` | Show diff for modified files | 顯示修改檔案的差異 |
32
33
  | `--restore` | Restore all modified and missing files | 還原所有修改和遺失的檔案 |
@@ -35,6 +36,23 @@ uds check --restore
35
36
 
36
37
  ## Output Sections | 輸出區段
37
38
 
39
+ ### Summary Mode (--summary) | 摘要模式
40
+
41
+ When using `--summary`, shows compact status for use by other commands:
42
+
43
+ 使用 `--summary` 時,顯示供其他命令使用的精簡狀態:
44
+
45
+ ```
46
+ UDS Status Summary
47
+ ──────────────────────────────────────────────────
48
+ Version: 3.5.1-beta.16 ✓
49
+ Level: 2 - Recommended (推薦)
50
+ Files: 12 ✓
51
+ Skills: Claude Code ✓ | OpenCode ○
52
+ Commands: OpenCode ✓
53
+ ──────────────────────────────────────────────────
54
+ ```
55
+
38
56
  ### Adoption Status | 採用狀態
39
57
  - Adoption level (1-3)
40
58
  - Installation date
@@ -16,6 +16,20 @@ When invoked without a specific type, use AskUserQuestion to ask what to configu
16
16
 
17
17
  當不指定類型時,使用 AskUserQuestion 詢問要配置什麼。
18
18
 
19
+ ### Step 0: Show Current Status | 步驟 0:顯示目前狀態
20
+
21
+ First, run `uds check --summary` to show current installation status.
22
+
23
+ 首先,執行 `uds check --summary` 顯示目前安裝狀態。
24
+
25
+ ```bash
26
+ uds check --summary
27
+ ```
28
+
29
+ This helps users understand what's currently configured before making changes.
30
+
31
+ 這幫助用戶在修改前了解目前的配置。
32
+
19
33
  ### Step 1: Ask Configuration Type | 步驟 1:詢問配置類型
20
34
 
21
35
  Use AskUserQuestion with these options:
@@ -18,7 +18,15 @@ When invoked without `--yes`, use AskUserQuestion to confirm update preferences.
18
18
 
19
19
  ### Step 1: Check Current Status | 步驟 1:檢查目前狀態
20
20
 
21
- First, run `uds check` to show current installation status and available updates.
21
+ First, run `uds check --summary` to show compact installation status.
22
+
23
+ 首先,執行 `uds check --summary` 顯示精簡安裝狀態。
24
+
25
+ ```bash
26
+ uds check --summary
27
+ ```
28
+
29
+ This shows: version (with update indicator), level, files status, Skills status, and Commands status.
22
30
 
23
31
  ### Step 2: Ask Update Preferences | 步驟 2:詢問更新偏好
24
32
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "universal-dev-standards",
3
- "version": "3.5.1-beta.16",
3
+ "version": "3.5.1-beta.17",
4
4
  "description": "CLI tool for adopting Universal Development Standards",
5
5
  "keywords": [
6
6
  "documentation",
@@ -43,6 +43,7 @@
43
43
  "test:e2e": "vitest run tests/e2e/",
44
44
  "test:all": "vitest run && vitest run tests/e2e/",
45
45
  "lint": "eslint src/",
46
+ "generate:e2e-spec": "node scripts/generate-e2e-spec.mjs",
46
47
  "prepare": "node ../scripts/setup-husky.mjs",
47
48
  "prepack": "node scripts/prepack.mjs"
48
49
  },