universal-dev-standards 5.0.0-rc.8 → 5.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.
- package/bin/uds.js +5 -3
- package/bundled/ai/standards/acceptance-criteria-traceability.ai.yaml +178 -0
- package/bundled/ai/standards/agent-dispatch.ai.yaml +69 -0
- package/bundled/ai/standards/ai-command-behavior.ai.yaml +45 -0
- package/bundled/ai/standards/api-design-standards.ai.yaml +192 -0
- package/bundled/ai/standards/branch-completion.ai.yaml +82 -0
- package/bundled/ai/standards/change-batching-standards.ai.yaml +195 -0
- package/bundled/ai/standards/database-standards.ai.yaml +220 -0
- package/bundled/ai/standards/error-codes.ai.yaml +37 -2
- package/bundled/ai/standards/git-worktree.ai.yaml +77 -0
- package/bundled/ai/standards/logging.ai.yaml +21 -2
- package/bundled/ai/standards/model-selection.ai.yaml +81 -0
- package/bundled/ai/standards/pipeline-integration-standards.ai.yaml +184 -0
- package/bundled/ai/standards/systematic-debugging.ai.yaml +73 -0
- package/bundled/ai/standards/verification-evidence.ai.yaml +84 -0
- package/bundled/ai/standards/workflow-enforcement.ai.yaml +253 -0
- package/bundled/core/acceptance-criteria-traceability.md +293 -0
- package/bundled/core/agent-dispatch.md +149 -0
- package/bundled/core/ai-command-behavior.md +239 -0
- package/bundled/core/api-design-standards.md +938 -0
- package/bundled/core/branch-completion.md +158 -0
- package/bundled/core/change-batching-standards.md +257 -0
- package/bundled/core/checkin-standards.md +43 -6
- package/bundled/core/database-standards.md +828 -0
- package/bundled/core/error-code-standards.md +228 -2
- package/bundled/core/forward-derivation-standards.md +54 -2
- package/bundled/core/git-worktree.md +131 -0
- package/bundled/core/model-selection.md +153 -0
- package/bundled/core/pipeline-integration-standards.md +230 -0
- package/bundled/core/systematic-debugging.md +156 -0
- package/bundled/core/testing-standards.md +49 -39
- package/bundled/core/verification-evidence.md +172 -0
- package/bundled/core/workflow-enforcement.md +132 -0
- package/bundled/locales/zh-CN/CLAUDE.md +2 -2
- package/bundled/locales/zh-CN/README.md +4 -4
- package/bundled/locales/zh-CN/SECURITY.md +92 -0
- package/bundled/locales/zh-CN/core/acceptance-criteria-traceability.md +301 -0
- package/bundled/locales/zh-CN/core/acceptance-test-driven-development.md +47 -0
- package/bundled/locales/zh-CN/core/accessibility-standards.md +124 -0
- package/bundled/locales/zh-CN/core/agent-dispatch.md +113 -0
- package/bundled/locales/zh-CN/core/ai-agreement-standards.md +103 -0
- package/bundled/locales/zh-CN/core/ai-command-behavior.md +247 -0
- package/bundled/locales/zh-CN/core/api-design-standards.md +946 -0
- package/bundled/locales/zh-CN/core/behavior-driven-development.md +48 -0
- package/bundled/locales/zh-CN/core/branch-completion.md +112 -0
- package/bundled/locales/zh-CN/core/change-batching-standards.md +265 -0
- package/bundled/locales/zh-CN/core/checkin-standards.md +43 -5
- package/bundled/locales/zh-CN/core/context-aware-loading.md +106 -0
- package/bundled/locales/zh-CN/core/database-standards.md +836 -0
- package/bundled/locales/zh-CN/core/deployment-standards.md +80 -0
- package/bundled/locales/zh-CN/core/error-code-standards.md +2 -2
- package/bundled/locales/zh-CN/core/forward-derivation-standards.md +493 -0
- package/bundled/locales/zh-CN/core/git-worktree.md +101 -0
- package/bundled/locales/zh-CN/core/model-selection.md +112 -0
- package/bundled/locales/zh-CN/core/performance-standards.md +104 -0
- package/bundled/locales/zh-CN/core/pipeline-integration-standards.md +238 -0
- package/bundled/locales/zh-CN/core/project-context-memory.md +124 -0
- package/bundled/locales/zh-CN/core/requirement-engineering.md +49 -0
- package/bundled/locales/zh-CN/core/security-standards.md +100 -0
- package/bundled/locales/zh-CN/core/systematic-debugging.md +106 -0
- package/bundled/locales/zh-CN/core/test-governance.md +116 -0
- package/bundled/locales/zh-CN/core/testing-standards.md +392 -156
- package/bundled/locales/zh-CN/core/verification-evidence.md +118 -0
- package/bundled/locales/zh-CN/core/virtual-organization-standards.md +104 -0
- package/bundled/locales/zh-CN/core/workflow-enforcement.md +132 -0
- package/bundled/locales/zh-CN/docs/CHEATSHEET.md +27 -1
- package/bundled/locales/zh-CN/docs/CLI-INIT-OPTIONS.md +9 -1
- package/bundled/locales/zh-CN/docs/FEATURE-REFERENCE.md +37 -9
- package/bundled/locales/zh-CN/docs/USER-MANUAL.md +652 -0
- package/bundled/locales/zh-CN/integrations/github-copilot/copilot-instructions.md +1 -1
- package/bundled/locales/zh-CN/integrations/openspec/AGENTS.md +29 -4
- package/bundled/locales/zh-CN/integrations/spec-kit/AGENTS.md +143 -72
- package/bundled/locales/zh-CN/skills/ac-coverage-assistant/SKILL.md +126 -0
- package/bundled/locales/zh-CN/skills/api-design-assistant/SKILL.md +100 -0
- package/bundled/locales/zh-CN/skills/brainstorm-assistant/SKILL.md +119 -0
- package/bundled/locales/zh-CN/skills/ci-cd-assistant/SKILL.md +82 -0
- package/bundled/locales/zh-CN/skills/commands/ac-coverage.md +97 -0
- package/bundled/locales/zh-CN/skills/commands/api-design.md +94 -0
- package/bundled/locales/zh-CN/skills/commands/atdd.md +163 -0
- package/bundled/locales/zh-CN/skills/commands/audit.md +77 -0
- package/bundled/locales/zh-CN/skills/commands/bdd.md +1 -1
- package/bundled/locales/zh-CN/skills/commands/brainstorm.md +87 -0
- package/bundled/locales/zh-CN/skills/commands/changelog.md +63 -0
- package/bundled/locales/zh-CN/skills/commands/check.md +219 -0
- package/bundled/locales/zh-CN/skills/commands/checkin.md +61 -0
- package/bundled/locales/zh-CN/skills/commands/ci-cd.md +77 -0
- package/bundled/locales/zh-CN/skills/commands/commit.md +81 -0
- package/bundled/locales/zh-CN/skills/commands/config.md +207 -0
- package/bundled/locales/zh-CN/skills/commands/coverage.md +74 -0
- package/bundled/locales/zh-CN/skills/commands/database.md +78 -0
- package/bundled/locales/zh-CN/skills/commands/derive-all.md +58 -0
- package/bundled/locales/zh-CN/skills/commands/derive-atdd.md +54 -0
- package/bundled/locales/zh-CN/skills/commands/derive-bdd.md +53 -0
- package/bundled/locales/zh-CN/skills/commands/derive-tdd.md +54 -0
- package/bundled/locales/zh-CN/skills/commands/derive.md +78 -0
- package/bundled/locales/zh-CN/skills/commands/dev-workflow.md +119 -0
- package/bundled/locales/zh-CN/skills/commands/discover.md +86 -0
- package/bundled/locales/zh-CN/skills/commands/docgen.md +67 -0
- package/bundled/locales/zh-CN/skills/commands/docs.md +65 -0
- package/bundled/locales/zh-CN/skills/commands/durable.md +87 -0
- package/bundled/locales/zh-CN/skills/commands/guide.md +52 -0
- package/bundled/locales/zh-CN/skills/commands/incident.md +92 -0
- package/bundled/locales/zh-CN/skills/commands/init.md +272 -0
- package/bundled/locales/zh-CN/skills/commands/methodology.md +1 -1
- package/bundled/locales/zh-CN/skills/commands/metrics.md +73 -0
- package/bundled/locales/zh-CN/skills/commands/migrate.md +92 -0
- package/bundled/locales/zh-CN/skills/commands/pr.md +80 -0
- package/bundled/locales/zh-CN/skills/commands/refactor.md +1 -1
- package/bundled/locales/zh-CN/skills/commands/release.md +62 -0
- package/bundled/locales/zh-CN/skills/commands/requirement.md +54 -0
- package/bundled/locales/zh-CN/skills/commands/reverse-bdd.md +47 -0
- package/bundled/locales/zh-CN/skills/commands/reverse-sdd.md +51 -0
- package/bundled/locales/zh-CN/skills/commands/reverse-tdd.md +51 -0
- package/bundled/locales/zh-CN/skills/commands/reverse.md +63 -0
- package/bundled/locales/zh-CN/skills/commands/review.md +50 -0
- package/bundled/locales/zh-CN/skills/commands/scan.md +76 -0
- package/bundled/locales/zh-CN/skills/commands/sdd-retro.md +40 -0
- package/bundled/locales/zh-CN/skills/commands/sdd.md +379 -0
- package/bundled/locales/zh-CN/skills/commands/security.md +75 -0
- package/bundled/locales/zh-CN/skills/commands/tdd.md +111 -0
- package/bundled/locales/zh-CN/skills/commands/update.md +337 -0
- package/bundled/locales/zh-CN/skills/commit-standards/SKILL.md +1 -2
- package/bundled/locales/zh-CN/skills/database-assistant/SKILL.md +97 -0
- package/bundled/locales/zh-CN/skills/dev-workflow-guide/SKILL.md +145 -0
- package/bundled/locales/zh-CN/skills/durable-execution-assistant/SKILL.md +84 -0
- package/bundled/locales/zh-CN/skills/incident-response-assistant/SKILL.md +107 -0
- package/bundled/locales/zh-CN/skills/metrics-dashboard-assistant/SKILL.md +67 -0
- package/bundled/locales/zh-CN/skills/migration-assistant/SKILL.md +77 -0
- package/bundled/locales/zh-CN/skills/pr-automation-assistant/SKILL.md +90 -0
- package/bundled/locales/zh-CN/skills/security-assistant/SKILL.md +79 -0
- package/bundled/locales/zh-CN/skills/security-scan-assistant/SKILL.md +72 -0
- package/bundled/locales/zh-CN/skills/spec-driven-dev/SKILL.md +73 -10
- package/bundled/locales/zh-CN/skills/spec-driven-dev/guide.md +267 -122
- package/bundled/locales/zh-TW/CLAUDE.md +2 -2
- package/bundled/locales/zh-TW/README.md +4 -4
- package/bundled/locales/zh-TW/SECURITY.md +92 -0
- package/bundled/locales/zh-TW/core/acceptance-criteria-traceability.md +301 -0
- package/bundled/locales/zh-TW/core/acceptance-test-driven-development.md +47 -0
- package/bundled/locales/zh-TW/core/accessibility-standards.md +84 -0
- package/bundled/locales/zh-TW/core/agent-dispatch.md +89 -0
- package/bundled/locales/zh-TW/core/ai-agreement-standards.md +87 -0
- package/bundled/locales/zh-TW/core/ai-command-behavior.md +247 -0
- package/bundled/locales/zh-TW/core/api-design-standards.md +946 -0
- package/bundled/locales/zh-TW/core/behavior-driven-development.md +63 -0
- package/bundled/locales/zh-TW/core/branch-completion.md +76 -0
- package/bundled/locales/zh-TW/core/change-batching-standards.md +265 -0
- package/bundled/locales/zh-TW/core/checkin-standards.md +39 -5
- package/bundled/locales/zh-TW/core/context-aware-loading.md +86 -0
- package/bundled/locales/zh-TW/core/database-standards.md +836 -0
- package/bundled/locales/zh-TW/core/deployment-standards.md +66 -0
- package/bundled/locales/zh-TW/core/error-code-standards.md +230 -4
- package/bundled/locales/zh-TW/core/forward-derivation-standards.md +62 -2
- package/bundled/locales/zh-TW/core/git-worktree.md +104 -0
- package/bundled/locales/zh-TW/core/model-selection.md +83 -0
- package/bundled/locales/zh-TW/core/performance-standards.md +84 -0
- package/bundled/locales/zh-TW/core/pipeline-integration-standards.md +238 -0
- package/bundled/locales/zh-TW/core/project-context-memory.md +79 -0
- package/bundled/locales/zh-TW/core/requirement-engineering.md +79 -0
- package/bundled/locales/zh-TW/core/security-standards.md +74 -0
- package/bundled/locales/zh-TW/core/systematic-debugging.md +95 -0
- package/bundled/locales/zh-TW/core/test-governance.md +88 -0
- package/bundled/locales/zh-TW/core/testing-standards.md +309 -86
- package/bundled/locales/zh-TW/core/verification-evidence.md +94 -0
- package/bundled/locales/zh-TW/core/virtual-organization-standards.md +88 -0
- package/bundled/locales/zh-TW/core/workflow-enforcement.md +132 -0
- package/bundled/locales/zh-TW/docs/CHEATSHEET.md +27 -1
- package/bundled/locales/zh-TW/docs/CLI-INIT-OPTIONS.md +9 -1
- package/bundled/locales/zh-TW/docs/FEATURE-REFERENCE.md +37 -9
- package/bundled/locales/zh-TW/docs/USER-MANUAL.md +652 -0
- package/bundled/locales/zh-TW/integrations/github-copilot/copilot-instructions.md +1 -1
- package/bundled/locales/zh-TW/integrations/openspec/AGENTS.md +29 -4
- package/bundled/locales/zh-TW/integrations/spec-kit/AGENTS.md +142 -71
- package/bundled/locales/zh-TW/skills/ac-coverage-assistant/SKILL.md +127 -0
- package/bundled/locales/zh-TW/skills/ai-friendly-architecture/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/ai-instruction-standards/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/api-design-assistant/SKILL.md +97 -0
- package/bundled/locales/zh-TW/skills/atdd-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/audit-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/bdd-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/brainstorm-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/changelog-guide/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/checkin-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/ci-cd-assistant/SKILL.md +79 -0
- package/bundled/locales/zh-TW/skills/code-review-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/commands/ac-coverage.md +95 -0
- package/bundled/locales/zh-TW/skills/commands/api-design.md +92 -0
- package/bundled/locales/zh-TW/skills/commands/atdd.md +167 -0
- package/bundled/locales/zh-TW/skills/commands/audit.md +75 -0
- package/bundled/locales/zh-TW/skills/commands/bdd.md +1 -1
- package/bundled/locales/zh-TW/skills/commands/brainstorm.md +91 -0
- package/bundled/locales/zh-TW/skills/commands/changelog.md +67 -0
- package/bundled/locales/zh-TW/skills/commands/check.md +223 -0
- package/bundled/locales/zh-TW/skills/commands/checkin.md +65 -0
- package/bundled/locales/zh-TW/skills/commands/ci-cd.md +75 -0
- package/bundled/locales/zh-TW/skills/commands/commit.md +85 -0
- package/bundled/locales/zh-TW/skills/commands/config.md +211 -0
- package/bundled/locales/zh-TW/skills/commands/coverage.md +78 -0
- package/bundled/locales/zh-TW/skills/commands/database.md +76 -0
- package/bundled/locales/zh-TW/skills/commands/derive-all.md +62 -0
- package/bundled/locales/zh-TW/skills/commands/derive-atdd.md +58 -0
- package/bundled/locales/zh-TW/skills/commands/derive-bdd.md +54 -0
- package/bundled/locales/zh-TW/skills/commands/derive-tdd.md +55 -0
- package/bundled/locales/zh-TW/skills/commands/derive.md +79 -0
- package/bundled/locales/zh-TW/skills/commands/dev-workflow.md +120 -0
- package/bundled/locales/zh-TW/skills/commands/discover.md +87 -0
- package/bundled/locales/zh-TW/skills/commands/docgen.md +68 -0
- package/bundled/locales/zh-TW/skills/commands/docs.md +66 -0
- package/bundled/locales/zh-TW/skills/commands/durable.md +85 -0
- package/bundled/locales/zh-TW/skills/commands/guide.md +51 -0
- package/bundled/locales/zh-TW/skills/commands/incident.md +90 -0
- package/bundled/locales/zh-TW/skills/commands/init.md +273 -0
- package/bundled/locales/zh-TW/skills/commands/methodology.md +1 -1
- package/bundled/locales/zh-TW/skills/commands/metrics.md +71 -0
- package/bundled/locales/zh-TW/skills/commands/migrate.md +90 -0
- package/bundled/locales/zh-TW/skills/commands/pr.md +78 -0
- package/bundled/locales/zh-TW/skills/commands/refactor.md +1 -1
- package/bundled/locales/zh-TW/skills/commands/release.md +63 -0
- package/bundled/locales/zh-TW/skills/commands/requirement.md +61 -0
- package/bundled/locales/zh-TW/skills/commands/reverse-bdd.md +54 -0
- package/bundled/locales/zh-TW/skills/commands/reverse-sdd.md +58 -0
- package/bundled/locales/zh-TW/skills/commands/reverse-tdd.md +58 -0
- package/bundled/locales/zh-TW/skills/commands/reverse.md +70 -0
- package/bundled/locales/zh-TW/skills/commands/review.md +57 -0
- package/bundled/locales/zh-TW/skills/commands/scan.md +74 -0
- package/bundled/locales/zh-TW/skills/commands/sdd-retro.md +47 -0
- package/bundled/locales/zh-TW/skills/commands/sdd.md +362 -0
- package/bundled/locales/zh-TW/skills/commands/security.md +73 -0
- package/bundled/locales/zh-TW/skills/commands/tdd.md +115 -0
- package/bundled/locales/zh-TW/skills/commands/update.md +326 -0
- package/bundled/locales/zh-TW/skills/commit-standards/SKILL.md +2 -6
- package/bundled/locales/zh-TW/skills/database-assistant/SKILL.md +94 -0
- package/bundled/locales/zh-TW/skills/dev-workflow-guide/SKILL.md +140 -0
- package/bundled/locales/zh-TW/skills/docs-generator/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/documentation-guide/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/durable-execution-assistant/SKILL.md +81 -0
- package/bundled/locales/zh-TW/skills/error-code-guide/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/forward-derivation/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/git-workflow-guide/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/incident-response-assistant/SKILL.md +104 -0
- package/bundled/locales/zh-TW/skills/logging-guide/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/methodology-system/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/metrics-dashboard-assistant/SKILL.md +64 -0
- package/bundled/locales/zh-TW/skills/migration-assistant/SKILL.md +74 -0
- package/bundled/locales/zh-TW/skills/pr-automation-assistant/SKILL.md +87 -0
- package/bundled/locales/zh-TW/skills/project-discovery/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/refactoring-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/release-standards/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/requirement-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/reverse-engineer/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/security-assistant/SKILL.md +76 -0
- package/bundled/locales/zh-TW/skills/security-scan-assistant/SKILL.md +69 -0
- package/bundled/locales/zh-TW/skills/spec-driven-dev/SKILL.md +74 -14
- package/bundled/locales/zh-TW/skills/spec-driven-dev/guide.md +243 -98
- package/bundled/locales/zh-TW/skills/tdd-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/test-coverage-assistant/SKILL.md +1 -4
- package/bundled/locales/zh-TW/skills/testing-guide/SKILL.md +1 -5
- package/bundled/skills/README.md +11 -0
- package/bundled/skills/ac-coverage-assistant/SKILL.md +127 -0
- package/bundled/skills/ai-collaboration-standards/SKILL.md +10 -0
- package/bundled/skills/ai-friendly-architecture/SKILL.md +10 -0
- package/bundled/skills/ai-instruction-standards/SKILL.md +10 -0
- package/bundled/skills/api-design-assistant/SKILL.md +119 -0
- package/bundled/skills/atdd-assistant/SKILL.md +7 -0
- package/bundled/skills/bdd-assistant/SKILL.md +7 -0
- package/bundled/skills/brainstorm-assistant/SKILL.md +7 -0
- package/bundled/skills/checkin-assistant/SKILL.md +7 -0
- package/bundled/skills/ci-cd-assistant/SKILL.md +97 -0
- package/bundled/skills/code-review-assistant/SKILL.md +7 -0
- package/bundled/skills/commands/README.md +70 -0
- package/bundled/skills/commands/ac-coverage.md +135 -0
- package/bundled/skills/commands/api-design.md +86 -0
- package/bundled/skills/commands/atdd.md +69 -0
- package/bundled/skills/commands/audit.md +69 -0
- package/bundled/skills/commands/bdd.md +101 -0
- package/bundled/skills/commands/brainstorm.md +45 -0
- package/bundled/skills/commands/changelog.md +34 -0
- package/bundled/skills/commands/check.md +52 -1
- package/bundled/skills/commands/checkin.md +46 -0
- package/bundled/skills/commands/ci-cd.md +69 -0
- package/bundled/skills/commands/commit.md +79 -0
- package/bundled/skills/commands/config.md +48 -0
- package/bundled/skills/commands/coverage.md +53 -0
- package/bundled/skills/commands/database.md +70 -0
- package/bundled/skills/commands/derive-all.md +40 -0
- package/bundled/skills/commands/derive-atdd.md +33 -0
- package/bundled/skills/commands/derive-bdd.md +39 -0
- package/bundled/skills/commands/derive-tdd.md +40 -0
- package/bundled/skills/commands/derive.md +47 -0
- package/bundled/skills/commands/dev-workflow.md +104 -7
- package/bundled/skills/commands/discover.md +39 -0
- package/bundled/skills/commands/docgen.md +35 -0
- package/bundled/skills/commands/docs.md +40 -0
- package/bundled/skills/commands/durable.md +79 -0
- package/bundled/skills/commands/incident.md +84 -0
- package/bundled/skills/commands/init.md +55 -0
- package/bundled/skills/commands/methodology.md +72 -0
- package/bundled/skills/commands/metrics.md +65 -0
- package/bundled/skills/commands/migrate.md +84 -0
- package/bundled/skills/commands/pr.md +72 -0
- package/bundled/skills/commands/refactor.md +51 -0
- package/bundled/skills/commands/release.md +60 -0
- package/bundled/skills/commands/requirement.md +38 -0
- package/bundled/skills/commands/reverse-bdd.md +34 -0
- package/bundled/skills/commands/reverse-sdd.md +42 -0
- package/bundled/skills/commands/reverse-tdd.md +40 -0
- package/bundled/skills/commands/reverse.md +41 -0
- package/bundled/skills/commands/review.md +39 -0
- package/bundled/skills/commands/scan.md +68 -0
- package/bundled/skills/commands/sdd-retro.md +48 -0
- package/bundled/skills/commands/sdd.md +220 -0
- package/bundled/skills/commands/security.md +67 -0
- package/bundled/skills/commands/tdd.md +101 -0
- package/bundled/skills/commands/update.md +61 -0
- package/bundled/skills/commit-standards/SKILL.md +8 -2
- package/bundled/skills/database-assistant/SKILL.md +118 -0
- package/bundled/skills/dev-workflow-guide/SKILL.md +53 -7
- package/bundled/skills/dev-workflow-guide/workflow-phases.md +24 -0
- package/bundled/skills/durable-execution-assistant/SKILL.md +116 -0
- package/bundled/skills/forward-derivation/SKILL.md +7 -0
- package/bundled/skills/incident-response-assistant/SKILL.md +132 -0
- package/bundled/skills/methodology-system/SKILL.md +24 -2
- package/bundled/skills/metrics-dashboard-assistant/SKILL.md +109 -0
- package/bundled/skills/migration-assistant/SKILL.md +119 -0
- package/bundled/skills/pr-automation-assistant/SKILL.md +114 -0
- package/bundled/skills/project-discovery/SKILL.md +7 -0
- package/bundled/skills/refactoring-assistant/SKILL.md +7 -0
- package/bundled/skills/release-standards/SKILL.md +7 -0
- package/bundled/skills/requirement-assistant/SKILL.md +7 -0
- package/bundled/skills/reverse-engineer/SKILL.md +7 -0
- package/bundled/skills/security-assistant/SKILL.md +105 -0
- package/bundled/skills/security-scan-assistant/SKILL.md +96 -0
- package/bundled/skills/spec-driven-dev/SKILL.md +84 -4
- package/bundled/skills/spec-driven-dev/guide.md +156 -22
- package/bundled/skills/tdd-assistant/SKILL.md +7 -0
- package/bundled/skills/test-coverage-assistant/SKILL.md +11 -0
- package/bundled/skills/testing-guide/SKILL.md +23 -0
- package/package.json +1 -1
- package/src/commands/check.js +154 -8
- package/src/commands/config.js +231 -104
- package/src/commands/init.js +23 -3
- package/src/commands/update.js +250 -25
- package/src/config/ai-agent-paths.js +16 -0
- package/src/config/workflow-definitions.js +184 -0
- package/src/core/constants.js +6 -0
- package/src/flows/init-flow.js +23 -6
- package/src/i18n/messages.js +51 -3
- package/src/installers/integration-installer.js +67 -2
- package/src/installers/manifest-installer.js +1 -0
- package/src/installers/standards-installer.js +3 -2
- package/src/prompts/init.js +50 -3
- package/src/reconciler/manifest-migrator.js +2 -2
- package/src/reconciler/plan-executor.js +11 -0
- package/src/utils/integration-generator.js +327 -14
- package/src/utils/workflow-gate.js +292 -0
- package/standards-registry.json +160 -5
|
@@ -3,15 +3,15 @@ scope: universal
|
|
|
3
3
|
description: |
|
|
4
4
|
Guide Spec-Driven Development (SDD) workflow for planning changes before implementation.
|
|
5
5
|
Use when: creating specs, proposals, planning features, using OpenSpec or similar tools.
|
|
6
|
-
Keywords: spec, specification, SDD, proposal, openspec, design doc, 規格, 提案, 設計文件.
|
|
6
|
+
Keywords: spec, specification, SDD, proposal, openspec, spec-kit, design doc, 規格, 提案, 設計文件.
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
# Spec-Driven Development Guide
|
|
10
10
|
|
|
11
11
|
> **Language**: English | [繁體中文](../../locales/zh-TW/skills/spec-driven-dev/SKILL.md)
|
|
12
12
|
|
|
13
|
-
**Version**: 1.
|
|
14
|
-
**Last Updated**: 2026-
|
|
13
|
+
**Version**: 1.2.0
|
|
14
|
+
**Last Updated**: 2026-03-23
|
|
15
15
|
**Applicability**: Claude Code Skills
|
|
16
16
|
|
|
17
17
|
---
|
|
@@ -20,6 +20,14 @@ description: |
|
|
|
20
20
|
|
|
21
21
|
This skill guides you through Spec-Driven Development (SDD), ensuring changes are planned, documented, and approved before implementation.
|
|
22
22
|
|
|
23
|
+
## Session Start Protocol
|
|
24
|
+
|
|
25
|
+
At the start of each session:
|
|
26
|
+
|
|
27
|
+
1. **Check for active specs**: Search `docs/specs/`, `specs/`, `openspec/changes/`, or `.specify/` for in-progress work
|
|
28
|
+
2. **If active specs found** → Inform user and offer to resume
|
|
29
|
+
3. **Review context** before starting new work
|
|
30
|
+
|
|
23
31
|
## Quick Reference
|
|
24
32
|
|
|
25
33
|
### SDD Workflow
|
|
@@ -46,6 +54,18 @@ This skill guides you through Spec-Driven Development (SDD), ensuring changes ar
|
|
|
46
54
|
| **Verification** | Confirm implementation matches spec (max 3 iterations) | Test results, traceability matrix |
|
|
47
55
|
| **Archive** | Close and archive | Archived spec with links |
|
|
48
56
|
|
|
57
|
+
### Workflow Enforcement Gates
|
|
58
|
+
|
|
59
|
+
**CRITICAL**: Before executing any workflow phase, you MUST check prerequisites.
|
|
60
|
+
|
|
61
|
+
| Phase | Prerequisite | On Failure |
|
|
62
|
+
|-------|-------------|------------|
|
|
63
|
+
| Proposal | Discuss completed, scope locked | → Complete Discuss stage first |
|
|
64
|
+
| Implementation | Spec status = Approved | → Get approval first |
|
|
65
|
+
| Verification | All ACs have code + tests | → Complete implementation first |
|
|
66
|
+
| Commit (feat/fix) | Check active specs | → Suggest spec reference (Refs: SPEC-XXX) |
|
|
67
|
+
| Archive | All tasks completed, verified | → Complete remaining tasks |
|
|
68
|
+
|
|
49
69
|
### Core Principles
|
|
50
70
|
|
|
51
71
|
| Principle | Description |
|
|
@@ -55,6 +75,7 @@ This skill guides you through Spec-Driven Development (SDD), ensuring changes ar
|
|
|
55
75
|
| **Tool Priority** | Use SDD tool commands when available |
|
|
56
76
|
| **Methodology > Tooling** | SDD works with any tool or manual process |
|
|
57
77
|
| **Bidirectional Sync** | Changes propagate to all related artifacts |
|
|
78
|
+
| **Simplicity First** | Choose the simplest solution that works |
|
|
58
79
|
|
|
59
80
|
### Pre-Spec Evaluation
|
|
60
81
|
|
|
@@ -66,10 +87,114 @@ Before creating a specification, answer these questions:
|
|
|
66
87
|
| **Interactive?** | Yes / No | Determines if Skill needed |
|
|
67
88
|
| **User-triggered?** | Yes / No | Determines if Command needed |
|
|
68
89
|
|
|
90
|
+
### Before Creating Specs
|
|
91
|
+
|
|
92
|
+
- Always check if a similar spec already exists in the project
|
|
93
|
+
- Search existing specs directory before creating new ones
|
|
94
|
+
- Prefer modifying existing specs over creating duplicates
|
|
95
|
+
- If request is ambiguous, ask 1-2 clarifying questions before proceeding
|
|
96
|
+
|
|
69
97
|
### Exceptions to "Spec First"
|
|
70
98
|
|
|
71
99
|
- Critical hotfixes (restore service immediately, document later)
|
|
72
100
|
- Trivial changes (typos, comments, formatting)
|
|
101
|
+
- Dependency updates (non-breaking)
|
|
102
|
+
- Configuration changes
|
|
103
|
+
|
|
104
|
+
## Detailed Stage Guidelines
|
|
105
|
+
|
|
106
|
+
### Discuss Stage
|
|
107
|
+
|
|
108
|
+
The Discuss stage ensures all ambiguities are resolved before writing a spec.
|
|
109
|
+
|
|
110
|
+
#### 1. Establish Governing Principles
|
|
111
|
+
|
|
112
|
+
Define project conventions, constraints, and non-negotiables upfront:
|
|
113
|
+
|
|
114
|
+
- What are the project's core architectural decisions?
|
|
115
|
+
- What are the non-negotiable constraints (performance, security, compatibility)?
|
|
116
|
+
- Document in `project.md`, `CONTRIBUTING.md`, or equivalent
|
|
117
|
+
|
|
118
|
+
#### 2. Structured Clarification
|
|
119
|
+
|
|
120
|
+
List all ambiguous points as explicit questions and resolve each before proceeding:
|
|
121
|
+
|
|
122
|
+
```markdown
|
|
123
|
+
## Clarification Log
|
|
124
|
+
|
|
125
|
+
| # | Question | Options | Decision | Rationale |
|
|
126
|
+
|---|----------|---------|----------|-----------|
|
|
127
|
+
| 1 | Auth method? | OAuth2 / JWT / Session | OAuth2 | Industry standard, SSO support |
|
|
128
|
+
| 2 | Token storage? | Cookie / LocalStorage | HttpOnly Cookie | XSS protection |
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
#### 3. Lock Scope
|
|
132
|
+
|
|
133
|
+
- Define what is IN scope and what is OUT of scope
|
|
134
|
+
- Identify related specs that may be affected
|
|
135
|
+
- Build a `read_first` list of files/specs to review
|
|
136
|
+
|
|
137
|
+
### Implementation Stage
|
|
138
|
+
|
|
139
|
+
Follow a structured approach during implementation:
|
|
140
|
+
|
|
141
|
+
1. **Read proposal/spec thoroughly** — Understand all requirements and AC
|
|
142
|
+
2. **Create tasks checklist** — Break down into sequential tasks (in `tasks.md` or within the spec)
|
|
143
|
+
3. **Implement tasks sequentially** — Complete each task in order
|
|
144
|
+
4. **Update checklist after each completion** — Mark tasks as done
|
|
145
|
+
5. **Do NOT skip to next phase** until all tasks are completed
|
|
146
|
+
|
|
147
|
+
### Requirement Wording
|
|
148
|
+
|
|
149
|
+
Use precise language in specifications:
|
|
150
|
+
|
|
151
|
+
| Keyword | Meaning | Usage |
|
|
152
|
+
|---------|---------|-------|
|
|
153
|
+
| **SHALL/MUST** | Mandatory requirement | "The system SHALL validate input" |
|
|
154
|
+
| **SHOULD** | Recommended practice | "The API SHOULD return within 200ms" |
|
|
155
|
+
| **MAY** | Optional feature | "The UI MAY display a loading spinner" |
|
|
156
|
+
|
|
157
|
+
Avoid ambiguous words: "should try", "might need", "could possibly"
|
|
158
|
+
|
|
159
|
+
## Simplicity First
|
|
160
|
+
|
|
161
|
+
### Default Principles
|
|
162
|
+
|
|
163
|
+
- Default to <100 lines of new code per change
|
|
164
|
+
- Single-file implementations until proven insufficient
|
|
165
|
+
- Avoid frameworks without clear justification
|
|
166
|
+
- Choose boring, proven patterns over novel approaches
|
|
167
|
+
|
|
168
|
+
### Complexity Triggers
|
|
169
|
+
|
|
170
|
+
Only add complexity when you have concrete evidence:
|
|
171
|
+
|
|
172
|
+
| Trigger | Evidence Required |
|
|
173
|
+
|---------|-------------------|
|
|
174
|
+
| Performance optimization | Profiling data showing bottleneck |
|
|
175
|
+
| Abstraction layer | 3+ concrete use cases requiring it |
|
|
176
|
+
| External dependency | Clear justification over built-in solution |
|
|
177
|
+
| Multi-service split | Scale requirements (>1000 users, >100MB data) |
|
|
178
|
+
|
|
179
|
+
## Naming Conventions
|
|
180
|
+
|
|
181
|
+
### Spec IDs
|
|
182
|
+
|
|
183
|
+
- Format: `SPEC-NNN` (e.g., `SPEC-001`, `SPEC-042`)
|
|
184
|
+
- Sequential within the project
|
|
185
|
+
|
|
186
|
+
### Change IDs
|
|
187
|
+
|
|
188
|
+
- Format: kebab-case, verb-led
|
|
189
|
+
- Prefixes: `add-`, `update-`, `remove-`, `refactor-`
|
|
190
|
+
- Examples: `add-two-factor-auth`, `update-payment-flow`, `remove-legacy-api`
|
|
191
|
+
|
|
192
|
+
### Capability Names
|
|
193
|
+
|
|
194
|
+
- Format: verb-noun (e.g., `user-auth`, `payment-capture`)
|
|
195
|
+
- Single purpose per capability
|
|
196
|
+
- 10-minute understandability rule: if it takes longer to understand, split it
|
|
197
|
+
- Split if description needs "AND"
|
|
73
198
|
|
|
74
199
|
## Proposal Template
|
|
75
200
|
|
|
@@ -139,7 +264,7 @@ Reviewers should verify:
|
|
|
139
264
|
|
|
140
265
|
## Examples
|
|
141
266
|
|
|
142
|
-
###
|
|
267
|
+
### Good Practices
|
|
143
268
|
|
|
144
269
|
```markdown
|
|
145
270
|
# SPEC-001 Add OAuth2 Login
|
|
@@ -157,7 +282,7 @@ Add Google OAuth2 login to allow users to sign in with their Google accounts.
|
|
|
157
282
|
- [ ] Existing users are linked to Google account
|
|
158
283
|
```
|
|
159
284
|
|
|
160
|
-
###
|
|
285
|
+
### Bad Practices
|
|
161
286
|
|
|
162
287
|
```markdown
|
|
163
288
|
# Add login
|
|
@@ -170,12 +295,14 @@ Adding login.
|
|
|
170
295
|
|
|
171
296
|
## Common SDD Tools
|
|
172
297
|
|
|
173
|
-
| Tool | Description |
|
|
174
|
-
|
|
175
|
-
| **OpenSpec** | Specification management |
|
|
176
|
-
| **Spec Kit** |
|
|
298
|
+
| Tool | Description | Key Commands |
|
|
299
|
+
|------|-------------|--------------|
|
|
300
|
+
| **OpenSpec** | Specification management CLI | `openspec list`, `openspec show`, `openspec validate`, `openspec archive` |
|
|
301
|
+
| **Spec Kit** | Slash-command-driven SDD | `specify init`, `/specify`, `/clarify`, `/plan`, `/tasks`, `/implement` |
|
|
177
302
|
| **Manual** | No tool, file-based | Create `specs/SPEC-XXX.md` manually |
|
|
178
303
|
|
|
304
|
+
> **Note**: When an SDD tool is detected in the project, prioritize using its native commands over manual file editing for consistency and traceability.
|
|
305
|
+
|
|
179
306
|
## Sync Verification
|
|
180
307
|
|
|
181
308
|
After completing a spec, verify synchronization:
|
|
@@ -205,21 +332,24 @@ After completing a spec, verify synchronization:
|
|
|
205
332
|
|
|
206
333
|
### Do's
|
|
207
334
|
|
|
208
|
-
-
|
|
209
|
-
-
|
|
210
|
-
-
|
|
211
|
-
-
|
|
212
|
-
-
|
|
213
|
-
-
|
|
335
|
+
- Evaluate scope before creating spec
|
|
336
|
+
- Check for existing specs before creating new ones
|
|
337
|
+
- Keep specs focused and atomic (one change per spec)
|
|
338
|
+
- Include clear acceptance criteria with Given/When/Then
|
|
339
|
+
- Use SHALL/MUST for normative requirements
|
|
340
|
+
- Link specs to implementation PRs
|
|
341
|
+
- Archive specs after completion
|
|
342
|
+
- Verify sync status before closing
|
|
214
343
|
|
|
215
344
|
### Don'ts
|
|
216
345
|
|
|
217
|
-
-
|
|
218
|
-
-
|
|
219
|
-
-
|
|
220
|
-
-
|
|
221
|
-
-
|
|
222
|
-
-
|
|
346
|
+
- Start coding before spec approval
|
|
347
|
+
- Skip scope evaluation or the Discuss stage
|
|
348
|
+
- Modify scope during implementation without updating spec
|
|
349
|
+
- Leave specs in limbo (always close or archive)
|
|
350
|
+
- Skip verification step
|
|
351
|
+
- Forget to sync related artifacts
|
|
352
|
+
- Add complexity without concrete evidence of need
|
|
223
353
|
|
|
224
354
|
---
|
|
225
355
|
|
|
@@ -229,7 +359,10 @@ This skill supports project-specific configuration.
|
|
|
229
359
|
|
|
230
360
|
### Detection Order
|
|
231
361
|
|
|
232
|
-
1. Check for SDD tool in workspace
|
|
362
|
+
1. Check for SDD tool in workspace:
|
|
363
|
+
- `openspec/` directory → OpenSpec detected
|
|
364
|
+
- `.specify/` directory → Spec Kit detected
|
|
365
|
+
- `specs/` or `docs/specs/` → Manual file-based workflow
|
|
233
366
|
2. Check `CONTRIBUTING.md` for spec workflow documentation
|
|
234
367
|
3. If not found, **default to manual file-based workflow**
|
|
235
368
|
|
|
@@ -269,6 +402,7 @@ See `specs/TEMPLATE.md`
|
|
|
269
402
|
|
|
270
403
|
| Version | Date | Changes |
|
|
271
404
|
|---------|------|---------|
|
|
405
|
+
| 1.2.0 | 2026-03-23 | Added: Session Start Protocol, Workflow Enforcement Gates, Discuss Stage (Constitution + Clarify), Simplicity First, Naming Conventions, Implementation Stage enhancement, Requirement Wording, Search Guidance, updated Common SDD Tools |
|
|
272
406
|
| 1.1.0 | 2026-01-26 | Added: Pre-Spec Evaluation, Sync Verification, Sync Matrix, enhanced best practices |
|
|
273
407
|
| 1.0.0 | 2025-12-30 | Initial release |
|
|
274
408
|
|
|
@@ -72,3 +72,10 @@ After `/tdd` completes, the AI assistant should suggest:
|
|
|
72
72
|
|
|
73
73
|
- Detailed guide: [guide.md](./guide.md)
|
|
74
74
|
- Core standard: [test-driven-development.md](../../core/test-driven-development.md)
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
## AI Agent Behavior | AI 代理行為
|
|
78
|
+
|
|
79
|
+
> 完整的 AI 行為定義請參閱對應的命令文件:[`/tdd`](../commands/tdd.md#ai-agent-behavior--ai-代理行為)
|
|
80
|
+
>
|
|
81
|
+
> For complete AI agent behavior definition, see the corresponding command file: [`/tdd`](../commands/tdd.md#ai-agent-behavior--ai-代理行為)
|
|
@@ -12,6 +12,10 @@ Analyze test coverage across multiple dimensions and provide actionable recommen
|
|
|
12
12
|
|
|
13
13
|
多維度分析測試覆蓋率並提供可執行的建議。
|
|
14
14
|
|
|
15
|
+
> **Related**: For requirement-level coverage (which AC have tests?), use `/ac-coverage` instead. This skill (`/coverage`) focuses on code-level coverage (lines, branches, functions).
|
|
16
|
+
>
|
|
17
|
+
> **相關**:如需需求層級覆蓋率(哪些 AC 有對應測試?),請改用 `/ac-coverage`。此技能(`/coverage`)專注於程式碼層級覆蓋率。
|
|
18
|
+
|
|
15
19
|
## Coverage Dimensions | 覆蓋率維度
|
|
16
20
|
|
|
17
21
|
| Dimension | What it Measures | 測量內容 |
|
|
@@ -70,3 +74,10 @@ After `/coverage` completes, the AI assistant should suggest:
|
|
|
70
74
|
|
|
71
75
|
- Detailed guide: [guide.md](./guide.md)
|
|
72
76
|
- Core standard: [test-completeness-dimensions.md](../../core/test-completeness-dimensions.md)
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
## AI Agent Behavior | AI 代理行為
|
|
80
|
+
|
|
81
|
+
> 完整的 AI 行為定義請參閱對應的命令文件:[`/coverage`](../commands/coverage.md#ai-agent-behavior--ai-代理行為)
|
|
82
|
+
>
|
|
83
|
+
> For complete AI agent behavior definition, see the corresponding command file: [`/coverage`](../commands/coverage.md#ai-agent-behavior--ai-代理行為)
|
|
@@ -21,6 +21,29 @@ description: |
|
|
|
21
21
|
|
|
22
22
|
This skill provides testing pyramid standards and best practices for systematic testing, supporting both ISTQB and Industry Pyramid frameworks.
|
|
23
23
|
|
|
24
|
+
## Testing Skills Navigator | 測試技能導航
|
|
25
|
+
|
|
26
|
+
UDS provides 6 testing-related skills. Use this decision tree to find the right one:
|
|
27
|
+
|
|
28
|
+
```
|
|
29
|
+
What do you want to do? | 你想做什麼?
|
|
30
|
+
├── Measure code coverage (lines/branches/functions) → /coverage
|
|
31
|
+
├── Track which requirements have tests (AC traceability) → /ac-coverage
|
|
32
|
+
├── Develop with Test-Driven Development (Red-Green-Refactor) → /tdd
|
|
33
|
+
├── Write BDD scenarios (Given-When-Then) → /bdd
|
|
34
|
+
├── Define acceptance tests with stakeholders → /atdd
|
|
35
|
+
└── Learn testing standards and best practices → /testing (this skill)
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
| Skill | Focus | 焦點 |
|
|
39
|
+
|-------|-------|------|
|
|
40
|
+
| `/testing` | Standards and best practices reference | 測試標準與最佳實踐參考 |
|
|
41
|
+
| `/coverage` | Code-level coverage analysis | 程式碼層級覆蓋率分析 |
|
|
42
|
+
| `/ac-coverage` | Requirement-level AC traceability | 需求層級 AC 可追蹤性 |
|
|
43
|
+
| `/tdd` | Red-Green-Refactor development cycle | 紅-綠-重構開發循環 |
|
|
44
|
+
| `/bdd` | Behavior scenarios with Given-When-Then | Given-When-Then 行為場景 |
|
|
45
|
+
| `/atdd` | Acceptance criteria with stakeholders | 與利害關係人定義驗收條件 |
|
|
46
|
+
|
|
24
47
|
## Framework Selection
|
|
25
48
|
|
|
26
49
|
| Framework | Levels | Best For |
|
package/package.json
CHANGED
package/src/commands/check.js
CHANGED
|
@@ -34,6 +34,7 @@ import { getToolFormat } from '../core/constants.js';
|
|
|
34
34
|
import { checkForUpdates } from '../utils/npm-registry.js';
|
|
35
35
|
import { writeUpdateCache } from '../utils/update-checker.js';
|
|
36
36
|
import { StandardValidator } from '../utils/standard-validator.js';
|
|
37
|
+
import { WorkflowGate } from '../utils/workflow-gate.js';
|
|
37
38
|
import { t, getLanguage, setLanguage, isLanguageExplicitlySet } from '../i18n/messages.js';
|
|
38
39
|
|
|
39
40
|
/**
|
|
@@ -344,12 +345,18 @@ export async function checkCommand(options = {}) {
|
|
|
344
345
|
// Integration files check
|
|
345
346
|
checkIntegrationFiles(manifest, projectPath, msg);
|
|
346
347
|
|
|
348
|
+
// Universal AGENTS.md sync check
|
|
349
|
+
checkAgentsMdSync(manifest, projectPath, msg);
|
|
350
|
+
|
|
347
351
|
// Skills status
|
|
348
352
|
const { missingSkills, missingCommands } = displaySkillsStatus(manifest, projectPath, msg);
|
|
349
353
|
|
|
350
354
|
// Coverage report
|
|
351
355
|
displayCoverageReport(manifest, msg, common, projectPath);
|
|
352
356
|
|
|
357
|
+
// Workflow status
|
|
358
|
+
displayWorkflowStatus(projectPath);
|
|
359
|
+
|
|
353
360
|
// Final status
|
|
354
361
|
const allGood = fileStatus.missing.length === 0 &&
|
|
355
362
|
fileStatus.modified.length === 0;
|
|
@@ -588,7 +595,7 @@ async function restoreFiles(projectPath, manifest, files) {
|
|
|
588
595
|
/**
|
|
589
596
|
* Restore a single file
|
|
590
597
|
*/
|
|
591
|
-
async function restoreSingleFile(projectPath, manifest, relativePath, msg) {
|
|
598
|
+
export async function restoreSingleFile(projectPath, manifest, relativePath, msg) {
|
|
592
599
|
// Get msg if not passed (for backward compatibility)
|
|
593
600
|
if (!msg) {
|
|
594
601
|
msg = t().commands.check;
|
|
@@ -631,14 +638,15 @@ async function restoreSingleFile(projectPath, manifest, relativePath, msg) {
|
|
|
631
638
|
/**
|
|
632
639
|
* Update file hash in manifest
|
|
633
640
|
*/
|
|
634
|
-
function updateFileHash(projectPath, manifest, relativePath) {
|
|
635
|
-
const
|
|
641
|
+
export function updateFileHash(projectPath, manifest, relativePath) {
|
|
642
|
+
const normalizedPath = relativePath.replace(/\\/g, '/');
|
|
643
|
+
const fullPath = join(projectPath, normalizedPath);
|
|
636
644
|
const hashInfo = computeFileHash(fullPath);
|
|
637
645
|
if (hashInfo) {
|
|
638
646
|
if (!manifest.fileHashes) {
|
|
639
647
|
manifest.fileHashes = {};
|
|
640
648
|
}
|
|
641
|
-
manifest.fileHashes[
|
|
649
|
+
manifest.fileHashes[normalizedPath] = {
|
|
642
650
|
...hashInfo,
|
|
643
651
|
installedAt: new Date().toISOString()
|
|
644
652
|
};
|
|
@@ -664,7 +672,7 @@ function removeFromManifest(manifest, relativePath) {
|
|
|
664
672
|
/**
|
|
665
673
|
* Get source path from relative path
|
|
666
674
|
*/
|
|
667
|
-
function getSourcePathFromRelative(manifest, relativePath) {
|
|
675
|
+
export function getSourcePathFromRelative(manifest, relativePath) {
|
|
668
676
|
const fileName = basename(relativePath);
|
|
669
677
|
|
|
670
678
|
// Check standards
|
|
@@ -712,9 +720,9 @@ async function migrateToHashBasedTracking(projectPath, manifest) {
|
|
|
712
720
|
// Process standards
|
|
713
721
|
for (const std of manifest.standards) {
|
|
714
722
|
const fileName = basename(std);
|
|
715
|
-
const relativePath = std.includes('options/')
|
|
723
|
+
const relativePath = (std.includes('options/')
|
|
716
724
|
? join('.standards', 'options', fileName)
|
|
717
|
-
: join('.standards', fileName);
|
|
725
|
+
: join('.standards', fileName)).replace(/\\/g, '/');
|
|
718
726
|
const fullPath = join(projectPath, relativePath);
|
|
719
727
|
|
|
720
728
|
const hashInfo = computeFileHash(fullPath);
|
|
@@ -728,7 +736,7 @@ async function migrateToHashBasedTracking(projectPath, manifest) {
|
|
|
728
736
|
for (const ext of manifest.extensions) {
|
|
729
737
|
if (typeof ext !== 'string') continue;
|
|
730
738
|
const fileName = basename(ext);
|
|
731
|
-
const relativePath = join('.standards', fileName);
|
|
739
|
+
const relativePath = join('.standards', fileName).replace(/\\/g, '/');
|
|
732
740
|
const fullPath = join(projectPath, relativePath);
|
|
733
741
|
|
|
734
742
|
const hashInfo = computeFileHash(fullPath);
|
|
@@ -1039,6 +1047,70 @@ function checkIntegrationFiles(manifest, projectPath, msg) {
|
|
|
1039
1047
|
console.log();
|
|
1040
1048
|
}
|
|
1041
1049
|
|
|
1050
|
+
/**
|
|
1051
|
+
* Check universal AGENTS.md sync with installed standards
|
|
1052
|
+
* Verifies the standards listed in AGENTS.md match the manifest
|
|
1053
|
+
*/
|
|
1054
|
+
function checkAgentsMdSync(manifest, projectPath, msg) {
|
|
1055
|
+
// Skip if generateAgentsMd is not enabled
|
|
1056
|
+
if (!manifest.generateAgentsMd) {
|
|
1057
|
+
return;
|
|
1058
|
+
}
|
|
1059
|
+
|
|
1060
|
+
// Skip if codex/opencode already handles AGENTS.md
|
|
1061
|
+
const hasAgentsMdTool = (manifest.aiTools || []).some(t => t === 'codex' || t === 'opencode');
|
|
1062
|
+
if (hasAgentsMdTool) {
|
|
1063
|
+
return;
|
|
1064
|
+
}
|
|
1065
|
+
|
|
1066
|
+
const agentsMdPath = join(projectPath, 'AGENTS.md');
|
|
1067
|
+
|
|
1068
|
+
console.log(chalk.cyan(msg.agentsMdSyncCheck || 'AGENTS.md Standards Sync'));
|
|
1069
|
+
|
|
1070
|
+
if (!existsSync(agentsMdPath)) {
|
|
1071
|
+
console.log(chalk.red(` ✗ AGENTS.md ${msg.missing || 'missing'}`));
|
|
1072
|
+
console.log(chalk.gray(` ${msg.runUpdateToRestore || 'Run "uds update" to restore'}`));
|
|
1073
|
+
console.log();
|
|
1074
|
+
return;
|
|
1075
|
+
}
|
|
1076
|
+
|
|
1077
|
+
const content = readFileSync(agentsMdPath, 'utf-8');
|
|
1078
|
+
const installedStandards = (manifest.standards || []).map(s => basename(s));
|
|
1079
|
+
|
|
1080
|
+
// Check standards listed in AGENTS.md vs manifest
|
|
1081
|
+
const aiYamlStandards = installedStandards.filter(s => s.endsWith('.ai.yaml'));
|
|
1082
|
+
let listedCount = 0;
|
|
1083
|
+
let missingFromAgentsMd = [];
|
|
1084
|
+
|
|
1085
|
+
for (const std of aiYamlStandards) {
|
|
1086
|
+
if (content.includes(std)) {
|
|
1087
|
+
listedCount++;
|
|
1088
|
+
} else {
|
|
1089
|
+
missingFromAgentsMd.push(std);
|
|
1090
|
+
}
|
|
1091
|
+
}
|
|
1092
|
+
|
|
1093
|
+
if (missingFromAgentsMd.length === 0) {
|
|
1094
|
+
console.log(chalk.green(` ✓ AGENTS.md ${msg.standardsSynced || 'standards synced'} (${listedCount}/${aiYamlStandards.length})`));
|
|
1095
|
+
} else {
|
|
1096
|
+
console.log(chalk.yellow(` ⚠ AGENTS.md ${msg.standardsOutOfSync || 'standards out of sync'} (${listedCount}/${aiYamlStandards.length})`));
|
|
1097
|
+
if (missingFromAgentsMd.length <= 5) {
|
|
1098
|
+
console.log(chalk.gray(` ${msg.missingInAgentsMd || 'Missing'}: ${missingFromAgentsMd.join(', ')}`));
|
|
1099
|
+
} else {
|
|
1100
|
+
console.log(chalk.gray(` ${msg.missingInAgentsMd || 'Missing'}: ${missingFromAgentsMd.slice(0, 5).join(', ')}... (+${missingFromAgentsMd.length - 5})`));
|
|
1101
|
+
}
|
|
1102
|
+
console.log(chalk.gray(` ${msg.runUpdateToSync || 'Run "uds update" to sync'}`));
|
|
1103
|
+
}
|
|
1104
|
+
|
|
1105
|
+
// Check line count
|
|
1106
|
+
const lineCount = content.split('\n').length;
|
|
1107
|
+
if (lineCount > 150) {
|
|
1108
|
+
console.log(chalk.yellow(` ⚠ AGENTS.md ${msg.exceedsLineLimit || 'exceeds 150 line limit'} (${lineCount} lines)`));
|
|
1109
|
+
}
|
|
1110
|
+
|
|
1111
|
+
console.log();
|
|
1112
|
+
}
|
|
1113
|
+
|
|
1042
1114
|
/**
|
|
1043
1115
|
* Check reference sync status between manifest standards and integration files
|
|
1044
1116
|
*/
|
|
@@ -1445,6 +1517,12 @@ async function displaySummary(projectPath, _options = {}) {
|
|
|
1445
1517
|
console.log(` ${summaryMsg.commands || 'Commands'}: ${commandsStatus}`);
|
|
1446
1518
|
}
|
|
1447
1519
|
|
|
1520
|
+
// === Row 6: Workflow Status ===
|
|
1521
|
+
const workflowStatus = getWorkflowStatusSummary(projectPath);
|
|
1522
|
+
if (workflowStatus) {
|
|
1523
|
+
console.log(` ${summaryMsg.workflow || 'Workflow'}: ${workflowStatus}`);
|
|
1524
|
+
}
|
|
1525
|
+
|
|
1448
1526
|
console.log(chalk.gray('─'.repeat(50)));
|
|
1449
1527
|
console.log();
|
|
1450
1528
|
}
|
|
@@ -1569,3 +1647,71 @@ function getCommandsStatusSummary(manifest, projectPath) {
|
|
|
1569
1647
|
|
|
1570
1648
|
return parts.length > 0 ? parts.join(' | ') : null;
|
|
1571
1649
|
}
|
|
1650
|
+
|
|
1651
|
+
/**
|
|
1652
|
+
* Get workflow status summary string (for --summary mode)
|
|
1653
|
+
* @param {string} projectPath - Project root path
|
|
1654
|
+
* @returns {string|null} Formatted workflow status or null if no active workflows
|
|
1655
|
+
*/
|
|
1656
|
+
function getWorkflowStatusSummary(projectPath) {
|
|
1657
|
+
try {
|
|
1658
|
+
const gate = new WorkflowGate(projectPath);
|
|
1659
|
+
const active = gate.listActiveWorkflows();
|
|
1660
|
+
|
|
1661
|
+
if (active.length === 0) {
|
|
1662
|
+
return chalk.green('No active workflows ✓');
|
|
1663
|
+
}
|
|
1664
|
+
|
|
1665
|
+
const parts = active.map(wf => {
|
|
1666
|
+
const progress = wf.progress
|
|
1667
|
+
? `${wf.progress.percentage}%`
|
|
1668
|
+
: '';
|
|
1669
|
+
return chalk.yellow(`${wf.workflowName}:${wf.currentStep || '?'} ${progress}`);
|
|
1670
|
+
});
|
|
1671
|
+
|
|
1672
|
+
return parts.join(' | ') + chalk.yellow(` (${active.length} active)`);
|
|
1673
|
+
} catch {
|
|
1674
|
+
return null;
|
|
1675
|
+
}
|
|
1676
|
+
}
|
|
1677
|
+
|
|
1678
|
+
/**
|
|
1679
|
+
* Display workflow status in full check mode
|
|
1680
|
+
* @param {string} projectPath - Project root path
|
|
1681
|
+
*/
|
|
1682
|
+
function displayWorkflowStatus(projectPath) {
|
|
1683
|
+
try {
|
|
1684
|
+
const gate = new WorkflowGate(projectPath);
|
|
1685
|
+
const active = gate.listActiveWorkflows();
|
|
1686
|
+
|
|
1687
|
+
if (active.length === 0) return;
|
|
1688
|
+
|
|
1689
|
+
console.log(chalk.cyan('Workflow Status | 工作流程狀態'));
|
|
1690
|
+
console.log();
|
|
1691
|
+
|
|
1692
|
+
for (const wf of active) {
|
|
1693
|
+
const progress = wf.progress
|
|
1694
|
+
? `${wf.progress.completed}/${wf.progress.total} (${wf.progress.percentage}%)`
|
|
1695
|
+
: 'unknown';
|
|
1696
|
+
const statusColor = wf.status === 'paused' ? chalk.yellow : chalk.blue;
|
|
1697
|
+
|
|
1698
|
+
console.log(` ${statusColor('●')} ${chalk.bold(wf.workflowName)} — ${wf.status}`);
|
|
1699
|
+
console.log(chalk.gray(` Step: ${wf.currentStep || 'N/A'} | Progress: ${progress}`));
|
|
1700
|
+
|
|
1701
|
+
// Staleness warning
|
|
1702
|
+
if (wf.updatedAt) {
|
|
1703
|
+
const updatedDate = new Date(wf.updatedAt);
|
|
1704
|
+
const daysSince = Math.floor((Date.now() - updatedDate.getTime()) / (1000 * 60 * 60 * 24));
|
|
1705
|
+
if (daysSince > 7) {
|
|
1706
|
+
console.log(chalk.yellow(` ⚠ Stale: last updated ${daysSince} days ago`));
|
|
1707
|
+
} else {
|
|
1708
|
+
console.log(chalk.gray(` Updated: ${wf.updatedAt}`));
|
|
1709
|
+
}
|
|
1710
|
+
}
|
|
1711
|
+
}
|
|
1712
|
+
|
|
1713
|
+
console.log();
|
|
1714
|
+
} catch {
|
|
1715
|
+
// Silently skip if workflow gate not available
|
|
1716
|
+
}
|
|
1717
|
+
}
|