@danmoisan/drm-copilot-mcp 0.0.1
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/LICENSE +21 -0
- package/README.md +50 -0
- package/out/mcp-server.js +17323 -0
- package/package.json +36 -0
- package/resources/claude-customizations/.claude/agent-memory/orchestrator/MEMORY.md +3 -0
- package/resources/claude-customizations/.claude/agent-memory/orchestrator/feedback_repo_root_is_source_of_truth.md +11 -0
- package/resources/claude-customizations/.claude/agent-memory/orchestrator/feedback_vsce_verify_package_location.md +19 -0
- package/resources/claude-customizations/.claude/agent-memory/orchestrator/project_extension_location.md +11 -0
- package/resources/claude-customizations/.claude/agent-memory/prd-feature/MEMORY.md +1 -0
- package/resources/claude-customizations/.claude/agent-memory/prd-feature/project_push_down_pattern.md +13 -0
- package/resources/claude-customizations/.claude/agent-memory/task-researcher/MEMORY.md +3 -0
- package/resources/claude-customizations/.claude/agent-memory/task-researcher/project_push_down_claude_dir.md +11 -0
- package/resources/claude-customizations/.claude/agents/atomic-executor.md +135 -0
- package/resources/claude-customizations/.claude/agents/atomic-planner.md +71 -0
- package/resources/claude-customizations/.claude/agents/csharp-typed-engineer.md +69 -0
- package/resources/claude-customizations/.claude/agents/epic-review.md +40 -0
- package/resources/claude-customizations/.claude/agents/feature-review.md +136 -0
- package/resources/claude-customizations/.claude/agents/orchestrator.md +83 -0
- package/resources/claude-customizations/.claude/agents/powershell-typed-engineer.md +80 -0
- package/resources/claude-customizations/.claude/agents/prd-feature.md +42 -0
- package/resources/claude-customizations/.claude/agents/python-typed-engineer.md +72 -0
- package/resources/claude-customizations/.claude/agents/staged-review.md +41 -0
- package/resources/claude-customizations/.claude/agents/status-updater.md +41 -0
- package/resources/claude-customizations/.claude/agents/task-researcher.md +81 -0
- package/resources/claude-customizations/.claude/agents/typescript-engineer.md +24 -0
- package/resources/claude-customizations/.claude/hooks/check-powershell-test-purity.ps1 +111 -0
- package/resources/claude-customizations/.claude/hooks/check-python-test-purity.ps1 +146 -0
- package/resources/claude-customizations/.claude/hooks/enforce-evidence-locations.ps1 +150 -0
- package/resources/claude-customizations/.claude/hooks/enforce-powershell-batch-budget.ps1 +238 -0
- package/resources/claude-customizations/.claude/hooks/enforce-promotion-mcp-only.ps1 +147 -0
- package/resources/claude-customizations/.claude/hooks/enforce-python-batch-budget.ps1 +235 -0
- package/resources/claude-customizations/.claude/hooks/validate-bash.ps1 +69 -0
- package/resources/claude-customizations/.claude/hooks/validate-executor-output.ps1 +296 -0
- package/resources/claude-customizations/.claude/hooks/validate-feature-review-coverage.ps1 +389 -0
- package/resources/claude-customizations/.claude/hooks/validate-orchestrator-output.ps1 +141 -0
- package/resources/claude-customizations/.claude/hooks/validate-planner-output.ps1 +288 -0
- package/resources/claude-customizations/.claude/hooks/validate-required-artifact-output.ps1 +171 -0
- package/resources/claude-customizations/.claude/hooks/validate-task-researcher-output.ps1 +142 -0
- package/resources/claude-customizations/.claude/rules/csharp.md +62 -0
- package/resources/claude-customizations/.claude/rules/general-code-change.md +71 -0
- package/resources/claude-customizations/.claude/rules/general-unit-test.md +60 -0
- package/resources/claude-customizations/.claude/rules/powershell.md +97 -0
- package/resources/claude-customizations/.claude/rules/python-suppressions.md +143 -0
- package/resources/claude-customizations/.claude/rules/python.md +99 -0
- package/resources/claude-customizations/.claude/rules/self-explanatory-code-commenting.md +97 -0
- package/resources/claude-customizations/.claude/rules/tonality.md +80 -0
- package/resources/claude-customizations/.claude/rules/typescript-suppressions.md +66 -0
- package/resources/claude-customizations/.claude/rules/typescript.md +45 -0
- package/resources/claude-customizations/.claude/settings.json +144 -0
- package/resources/claude-customizations/.claude/skills/acceptance-criteria-tracking/SKILL.md +102 -0
- package/resources/claude-customizations/.claude/skills/atomic-plan-contract/SKILL.md +189 -0
- package/resources/claude-customizations/.claude/skills/commit-message/SKILL.md +65 -0
- package/resources/claude-customizations/.claude/skills/csharp-change-budget-router/SKILL.md +90 -0
- package/resources/claude-customizations/.claude/skills/csharp-orchestration-state-machine/SKILL.md +58 -0
- package/resources/claude-customizations/.claude/skills/csharp-qa-gate/SKILL.md +77 -0
- package/resources/claude-customizations/.claude/skills/evidence-and-timestamp-conventions/SKILL.md +164 -0
- package/resources/claude-customizations/.claude/skills/execute-hard-lock/SKILL.md +82 -0
- package/resources/claude-customizations/.claude/skills/feature-promotion-lifecycle/SKILL.md +115 -0
- package/resources/claude-customizations/.claude/skills/feature-review-workflow/SKILL.md +167 -0
- package/resources/claude-customizations/.claude/skills/fill-feature-docs/SKILL.md +22 -0
- package/resources/claude-customizations/.claude/skills/invoke-csharp-engineer/SKILL.md +64 -0
- package/resources/claude-customizations/.claude/skills/invoke-powershell-engineer/SKILL.md +65 -0
- package/resources/claude-customizations/.claude/skills/invoke-python-engineer/SKILL.md +64 -0
- package/resources/claude-customizations/.claude/skills/make-skill-template/SKILL.md +147 -0
- package/resources/claude-customizations/.claude/skills/orchestrate/SKILL.md +132 -0
- package/resources/claude-customizations/.claude/skills/policy-audit-template-usage/SKILL.md +49 -0
- package/resources/claude-customizations/.claude/skills/policy-compliance-order/SKILL.md +40 -0
- package/resources/claude-customizations/.claude/skills/powershell-change-budget-router/SKILL.md +49 -0
- package/resources/claude-customizations/.claude/skills/powershell-orchestration-state-machine/SKILL.md +58 -0
- package/resources/claude-customizations/.claude/skills/powershell-qa-gate/SKILL.md +77 -0
- package/resources/claude-customizations/.claude/skills/pr-author/SKILL.md +50 -0
- package/resources/claude-customizations/.claude/skills/pr-base-branch-merge-base/SKILL.md +56 -0
- package/resources/claude-customizations/.claude/skills/pr-context-artifacts/SKILL.md +30 -0
- package/resources/claude-customizations/.claude/skills/python-change-budget-router/SKILL.md +79 -0
- package/resources/claude-customizations/.claude/skills/python-qa-gate/SKILL.md +77 -0
- package/resources/claude-customizations/.claude/skills/remediation-handoff-atomic-planner/SKILL.md +40 -0
- package/resources/claude-customizations/.claude/skills/research-issue/SKILL.md +67 -0
- package/resources/claude-customizations/.claude/skills/review-epic/SKILL.md +21 -0
- package/resources/claude-customizations/.claude/skills/review-feature/SKILL.md +25 -0
- package/resources/claude-customizations/.claude/skills/review-staged/SKILL.md +21 -0
- package/resources/claude-customizations/.claude/skills/skill-canonical-location-audit/SKILL.md +49 -0
- package/resources/claude-customizations/.claude/skills/translate-copilot-to-claude/SKILL.md +295 -0
- package/resources/claude-customizations/.claude/skills/update-status/SKILL.md +21 -0
- package/resources/claude-dir-customizations/.mcp.json +8 -0
- package/resources/codex-and-agents-customizations/.agents/README.md +86 -0
- package/resources/codex-and-agents-customizations/.agents/skills/README.md +49 -0
- package/resources/codex-and-agents-customizations/.agents/skills/acceptance-criteria-tracking/SKILL.md +107 -0
- package/resources/codex-and-agents-customizations/.agents/skills/atomic-executor/SKILL.md +73 -0
- package/resources/codex-and-agents-customizations/.agents/skills/atomic-plan-contract/SKILL.md +194 -0
- package/resources/codex-and-agents-customizations/.agents/skills/atomic-planner/SKILL.md +87 -0
- package/resources/codex-and-agents-customizations/.agents/skills/commit-message/SKILL.md +70 -0
- package/resources/codex-and-agents-customizations/.agents/skills/commit-message-conventions/SKILL.md +95 -0
- package/resources/codex-and-agents-customizations/.agents/skills/csharp/SKILL.md +67 -0
- package/resources/codex-and-agents-customizations/.agents/skills/csharp-change-budget-router/SKILL.md +94 -0
- package/resources/codex-and-agents-customizations/.agents/skills/csharp-orchestration-state-machine/SKILL.md +64 -0
- package/resources/codex-and-agents-customizations/.agents/skills/csharp-qa-gate/SKILL.md +82 -0
- package/resources/codex-and-agents-customizations/.agents/skills/evidence-and-timestamp-conventions/SKILL.md +168 -0
- package/resources/codex-and-agents-customizations/.agents/skills/execute-hard-lock/SKILL.md +88 -0
- package/resources/codex-and-agents-customizations/.agents/skills/feature-promotion-lifecycle/SKILL.md +129 -0
- package/resources/codex-and-agents-customizations/.agents/skills/feature-review/SKILL.md +106 -0
- package/resources/codex-and-agents-customizations/.agents/skills/feature-review-workflow/SKILL.md +181 -0
- package/resources/codex-and-agents-customizations/.agents/skills/fill-feature-docs/SKILL.md +27 -0
- package/resources/codex-and-agents-customizations/.agents/skills/invoke-csharp-engineer/SKILL.md +73 -0
- package/resources/codex-and-agents-customizations/.agents/skills/invoke-powershell-engineer/SKILL.md +74 -0
- package/resources/codex-and-agents-customizations/.agents/skills/invoke-python-engineer/SKILL.md +73 -0
- package/resources/codex-and-agents-customizations/.agents/skills/make-skill-template/SKILL.md +152 -0
- package/resources/codex-and-agents-customizations/.agents/skills/orchestrate/SKILL.md +143 -0
- package/resources/codex-and-agents-customizations/.agents/skills/orchestrator-workflow/SKILL.md +317 -0
- package/resources/codex-and-agents-customizations/.agents/skills/policy-audit-template-usage/SKILL.md +53 -0
- package/resources/codex-and-agents-customizations/.agents/skills/policy-compliance-order/SKILL.md +49 -0
- package/resources/codex-and-agents-customizations/.agents/skills/powershell/SKILL.md +102 -0
- package/resources/codex-and-agents-customizations/.agents/skills/powershell-change-budget-router/SKILL.md +53 -0
- package/resources/codex-and-agents-customizations/.agents/skills/powershell-orchestration-state-machine/SKILL.md +64 -0
- package/resources/codex-and-agents-customizations/.agents/skills/powershell-qa-gate/SKILL.md +83 -0
- package/resources/codex-and-agents-customizations/.agents/skills/pr-author/SKILL.md +55 -0
- package/resources/codex-and-agents-customizations/.agents/skills/pr-authoring/SKILL.md +124 -0
- package/resources/codex-and-agents-customizations/.agents/skills/pr-base-branch-merge-base/SKILL.md +60 -0
- package/resources/codex-and-agents-customizations/.agents/skills/pr-context-artifacts/SKILL.md +34 -0
- package/resources/codex-and-agents-customizations/.agents/skills/python/SKILL.md +104 -0
- package/resources/codex-and-agents-customizations/.agents/skills/python-change-budget-router/SKILL.md +84 -0
- package/resources/codex-and-agents-customizations/.agents/skills/python-qa-gate/SKILL.md +82 -0
- package/resources/codex-and-agents-customizations/.agents/skills/python-suppressions/SKILL.md +148 -0
- package/resources/codex-and-agents-customizations/.agents/skills/remediation-handoff-atomic-planner/SKILL.md +49 -0
- package/resources/codex-and-agents-customizations/.agents/skills/repo-automation-adapter/SKILL.md +142 -0
- package/resources/codex-and-agents-customizations/.agents/skills/repo-automation-adapter/agents/openai.yaml +5 -0
- package/resources/codex-and-agents-customizations/.agents/skills/research-issue/SKILL.md +72 -0
- package/resources/codex-and-agents-customizations/.agents/skills/review-epic/SKILL.md +26 -0
- package/resources/codex-and-agents-customizations/.agents/skills/review-feature/SKILL.md +30 -0
- package/resources/codex-and-agents-customizations/.agents/skills/review-staged/SKILL.md +26 -0
- package/resources/codex-and-agents-customizations/.agents/skills/self-explanatory-code-commenting/SKILL.md +102 -0
- package/resources/codex-and-agents-customizations/.agents/skills/skill-canonical-location-audit/SKILL.md +52 -0
- package/resources/codex-and-agents-customizations/.agents/skills/translate-copilot-to-claude/SKILL.md +317 -0
- package/resources/codex-and-agents-customizations/.agents/skills/typescript/SKILL.md +50 -0
- package/resources/codex-and-agents-customizations/.agents/skills/typescript-suppressions/SKILL.md +71 -0
- package/resources/codex-and-agents-customizations/.agents/skills/update-status/SKILL.md +26 -0
- package/resources/codex-and-agents-customizations/.codex/agents/5.1-beast-adjusted.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/agents/5.1-thinking-beast-mode-adjusted.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/agents/api-architect.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/agents/atomic-executor.toml +151 -0
- package/resources/codex-and-agents-customizations/.codex/agents/atomic-planner.toml +93 -0
- package/resources/codex-and-agents-customizations/.codex/agents/atomic-planning.toml +24 -0
- package/resources/codex-and-agents-customizations/.codex/agents/commentary-remediation.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/agents/commit-steward.toml +20 -0
- package/resources/codex-and-agents-customizations/.codex/agents/csharp-atomic-executor.toml +24 -0
- package/resources/codex-and-agents-customizations/.codex/agents/csharp-atomic-planning.toml +25 -0
- package/resources/codex-and-agents-customizations/.codex/agents/csharp-orchestrator.toml +56 -0
- package/resources/codex-and-agents-customizations/.codex/agents/csharp-typed-engineer.toml +97 -0
- package/resources/codex-and-agents-customizations/.codex/agents/epic-review.toml +52 -0
- package/resources/codex-and-agents-customizations/.codex/agents/expert-nextjs-developer.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/agents/expert-react-frontend-engineer.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/agents/feature-review.toml +149 -0
- package/resources/codex-and-agents-customizations/.codex/agents/feature-reviewer.toml +60 -0
- package/resources/codex-and-agents-customizations/.codex/agents/gpt-5-beast-mode.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/agents/hlbpa.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/agents/mentor.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/agents/orchestrator.toml +121 -0
- package/resources/codex-and-agents-customizations/.codex/agents/powershell-atomic-executor.toml +24 -0
- package/resources/codex-and-agents-customizations/.codex/agents/powershell-atomic-planning.toml +25 -0
- package/resources/codex-and-agents-customizations/.codex/agents/powershell-di-unit-test-engineer.toml +24 -0
- package/resources/codex-and-agents-customizations/.codex/agents/powershell-orchestrator.toml +56 -0
- package/resources/codex-and-agents-customizations/.codex/agents/powershell-typed-engineer.toml +108 -0
- package/resources/codex-and-agents-customizations/.codex/agents/pr-author.toml +26 -0
- package/resources/codex-and-agents-customizations/.codex/agents/prd-feature.toml +53 -0
- package/resources/codex-and-agents-customizations/.codex/agents/prd.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/agents/pytest-unit-test-coding.toml +24 -0
- package/resources/codex-and-agents-customizations/.codex/agents/python-atomic-executor.toml +24 -0
- package/resources/codex-and-agents-customizations/.codex/agents/python-atomic-planning.toml +25 -0
- package/resources/codex-and-agents-customizations/.codex/agents/python-execution-only-typed.toml +24 -0
- package/resources/codex-and-agents-customizations/.codex/agents/python-orchestrator.toml +54 -0
- package/resources/codex-and-agents-customizations/.codex/agents/python-typed-engineer.toml +100 -0
- package/resources/codex-and-agents-customizations/.codex/agents/staged-review.toml +53 -0
- package/resources/codex-and-agents-customizations/.codex/agents/status-updater.toml +53 -0
- package/resources/codex-and-agents-customizations/.codex/agents/task-researcher.toml +103 -0
- package/resources/codex-and-agents-customizations/.codex/agents/tdd-green.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/agents/tdd-red.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/agents/tdd-refactor.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/agents/typescript-engineer.toml +48 -0
- package/resources/codex-and-agents-customizations/.codex/agents/voidbeast-gpt41enhanced.toml +23 -0
- package/resources/codex-and-agents-customizations/.codex/codex-web-setup.plan.md +26 -0
- package/resources/codex-and-agents-customizations/.codex/codex-web-setup.sh +384 -0
- package/resources/codex-and-agents-customizations/.codex/config.toml +137 -0
- package/resources/codex-and-agents-customizations/.codex/hooks/check-powershell-test-purity.ps1 +113 -0
- package/resources/codex-and-agents-customizations/.codex/hooks/check-python-test-purity.ps1 +149 -0
- package/resources/codex-and-agents-customizations/.codex/hooks/enforce-evidence-locations.ps1 +153 -0
- package/resources/codex-and-agents-customizations/.codex/hooks/enforce-powershell-batch-budget.ps1 +241 -0
- package/resources/codex-and-agents-customizations/.codex/hooks/enforce-promotion-mcp-only.ps1 +150 -0
- package/resources/codex-and-agents-customizations/.codex/hooks/enforce-python-batch-budget.ps1 +238 -0
- package/resources/codex-and-agents-customizations/.codex/hooks/validate-bash.ps1 +72 -0
- package/resources/codex-and-agents-customizations/.codex/hooks/validate-feature-review-coverage.ps1 +265 -0
- package/resources/codex-and-agents-customizations/.codex/prompts/feature-review-remediate.md +10 -0
- package/resources/codex-and-agents-customizations/.codex/prompts/generate-commit-message-repo.md +11 -0
- package/resources/codex-and-agents-customizations/.codex/prompts/generate-pr.md +15 -0
- package/resources/codex-and-agents-customizations/.codex/prompts/orchestrate-work.md +22 -0
- package/resources/codex-and-agents-customizations/AGENTS.md +317 -0
- package/resources/customizations/.github/agents/5.1-Beast-adjusted.agent.md +181 -0
- package/resources/customizations/.github/agents/5.1-Thinking-Beast-Mode-adjusted.agent.md +361 -0
- package/resources/customizations/.github/agents/Powershell DI Unit Test Engineer.agent.md +192 -0
- package/resources/customizations/.github/agents/api-architect.agent.md +40 -0
- package/resources/customizations/.github/agents/atomic_executor.agent.md +251 -0
- package/resources/customizations/.github/agents/atomic_planning.agent.md +658 -0
- package/resources/customizations/.github/agents/commentary-remediation.agent.md +35 -0
- package/resources/customizations/.github/agents/commit-steward.agent.md +200 -0
- package/resources/customizations/.github/agents/csharp-atomic-executor.agent.md +288 -0
- package/resources/customizations/.github/agents/csharp-atomic-planning.agent.md +354 -0
- package/resources/customizations/.github/agents/csharp-orchestrator.agent.md +375 -0
- package/resources/customizations/.github/agents/csharp-typed-engineer.agent.md +285 -0
- package/resources/customizations/.github/agents/epic-review.agent.md +374 -0
- package/resources/customizations/.github/agents/expert-nextjs-developer.agent.md +477 -0
- package/resources/customizations/.github/agents/expert-react-frontend-engineer.agent.md +739 -0
- package/resources/customizations/.github/agents/feature-review.agent.md +49 -0
- package/resources/customizations/.github/agents/gpt-5-beast-mode.agent.md +116 -0
- package/resources/customizations/.github/agents/hlbpa.agent.md +219 -0
- package/resources/customizations/.github/agents/mentor.agent.md +32 -0
- package/resources/customizations/.github/agents/orchestrator.agent.md +449 -0
- package/resources/customizations/.github/agents/powershell-atomic-executor.agent.md +287 -0
- package/resources/customizations/.github/agents/powershell-atomic-planning.agent.md +647 -0
- package/resources/customizations/.github/agents/powershell-orchestrator.agent.md +382 -0
- package/resources/customizations/.github/agents/powershell-typed-engineer.agent.md +293 -0
- package/resources/customizations/.github/agents/pr-author.agent.md +138 -0
- package/resources/customizations/.github/agents/prd-feature.agent.md +52 -0
- package/resources/customizations/.github/agents/prd.agent.md +202 -0
- package/resources/customizations/.github/agents/pytest-unit-test-coding.agent.md +202 -0
- package/resources/customizations/.github/agents/python-atomic-executor.agent.md +289 -0
- package/resources/customizations/.github/agents/python-atomic-planning.agent.md +429 -0
- package/resources/customizations/.github/agents/python-execution-only-typed.agent.md +217 -0
- package/resources/customizations/.github/agents/python-orchestrator.agent.md +380 -0
- package/resources/customizations/.github/agents/python-typed-engineer.agent.md +271 -0
- package/resources/customizations/.github/agents/staged-review.agent.md +246 -0
- package/resources/customizations/.github/agents/status_updater.agent.md +279 -0
- package/resources/customizations/.github/agents/task-researcher.agent.md +298 -0
- package/resources/customizations/.github/agents/tdd-green.agent.md +60 -0
- package/resources/customizations/.github/agents/tdd-red.agent.md +66 -0
- package/resources/customizations/.github/agents/tdd-refactor.agent.md +94 -0
- package/resources/customizations/.github/agents/typescript-engineer.agent.md +167 -0
- package/resources/customizations/.github/agents/voidbeast-gpt41enhanced.agent.md +230 -0
- package/resources/customizations/.github/codex/execute-hard-lock.prompt.md +105 -0
- package/resources/customizations/.github/codex/resume-hard-lock.prompt.md +92 -0
- package/resources/customizations/.github/copilot-instructions.md +7 -0
- package/resources/customizations/.github/instructions/csharp-code-change.instructions.md +184 -0
- package/resources/customizations/.github/instructions/csharp-unit-test.instructions.md +52 -0
- package/resources/customizations/.github/instructions/general-code-change.instructions.md +290 -0
- package/resources/customizations/.github/instructions/general-unit-test.instructions.md +106 -0
- package/resources/customizations/.github/instructions/github-actions-ci-cd-best-practices.instructions.md +607 -0
- package/resources/customizations/.github/instructions/github-actions.instructions.md +23 -0
- package/resources/customizations/.github/instructions/powershell-code-change.instructions.md +81 -0
- package/resources/customizations/.github/instructions/powershell-unit-test.instructions.md +69 -0
- package/resources/customizations/.github/instructions/python-code-change.instructions.md +232 -0
- package/resources/customizations/.github/instructions/python-suppressions.instructions.md +609 -0
- package/resources/customizations/.github/instructions/python-unit-test.instructions.md +71 -0
- package/resources/customizations/.github/instructions/self-explanatory-code-commenting.instructions.md +238 -0
- package/resources/customizations/.github/instructions/tonality.instructions.md +133 -0
- package/resources/customizations/.github/instructions/typescript-code-change.instructions.md +203 -0
- package/resources/customizations/.github/instructions/typescript-suppressions.instructions.md +157 -0
- package/resources/customizations/.github/instructions/typescript-unit-test.instructions.md +112 -0
- package/resources/customizations/.github/prompts/add-educational-comments.prompt.md +129 -0
- package/resources/customizations/.github/prompts/breakdown-bug-prd.prompt.md +29 -0
- package/resources/customizations/.github/prompts/breakdown-epic-arch.prompt.md +66 -0
- package/resources/customizations/.github/prompts/breakdown-epic-pm.prompt.md +58 -0
- package/resources/customizations/.github/prompts/breakdown-feature-implementation.prompt.md +128 -0
- package/resources/customizations/.github/prompts/breakdown-feature-prd.prompt.md +61 -0
- package/resources/customizations/.github/prompts/code-exemplars-blueprint-generator.prompt.md +126 -0
- package/resources/customizations/.github/prompts/drafts/create-github-issues-feature-from-implementation-plan.prompt.md +28 -0
- package/resources/customizations/.github/prompts/drafts/create-implementation-plan.prompt.md +158 -0
- package/resources/customizations/.github/prompts/drafts/create-technical-spike.prompt.md +231 -0
- package/resources/customizations/.github/prompts/drafts/potential-feature-prd.prompt.md +19 -0
- package/resources/customizations/.github/prompts/drafts/update-implementation-plan.prompt.md +158 -0
- package/resources/customizations/.github/prompts/execute-plan-template.md +21 -0
- package/resources/customizations/.github/prompts/export-chat.prompt.md +7 -0
- package/resources/customizations/.github/prompts/fillout-prd-feature.prompt.md +46 -0
- package/resources/customizations/.github/prompts/generate-atomic-plan.prompt.md +96 -0
- package/resources/customizations/.github/prompts/generate-commit-message-repo.prompt.md +108 -0
- package/resources/customizations/.github/prompts/generate-pr.prompt.md +151 -0
- package/resources/customizations/.github/prompts/javascript-typescript-jest.prompt.md +44 -0
- package/resources/customizations/.github/prompts/orchestrate-csharp-work.prompt.md +66 -0
- package/resources/customizations/.github/prompts/orchestrate-powershell-work.prompt.md +50 -0
- package/resources/customizations/.github/prompts/orchestrate-python-work.prompt.md +50 -0
- package/resources/customizations/.github/prompts/orchestrate-work.prompt.md +66 -0
- package/resources/customizations/.github/prompts/remediate-comments.prompt.md +53 -0
- package/resources/customizations/.github/prompts/research-issue.prompt.md +125 -0
- package/resources/customizations/.github/prompts/review-epic.prompt.md +94 -0
- package/resources/customizations/.github/prompts/review-feature.prompt.md +130 -0
- package/resources/customizations/.github/prompts/review-staged.prompt.md +43 -0
- package/resources/customizations/.github/prompts/update_status.prompt.md +68 -0
- package/resources/customizations/.github/skills/README.md +26 -0
- package/resources/customizations/.github/skills/acceptance-criteria-tracking/SKILL.md +102 -0
- package/resources/customizations/.github/skills/atomic-plan-contract/SKILL.md +174 -0
- package/resources/customizations/.github/skills/csharp-change-budget-router/SKILL.md +48 -0
- package/resources/customizations/.github/skills/csharp-orchestration-state-machine/SKILL.md +57 -0
- package/resources/customizations/.github/skills/evidence-and-timestamp-conventions/SKILL.md +135 -0
- package/resources/customizations/.github/skills/feature-promotion-lifecycle/SKILL.md +121 -0
- package/resources/customizations/.github/skills/feature-review-workflow/SKILL.md +153 -0
- package/resources/customizations/.github/skills/make-skill-template/SKILL.md +147 -0
- package/resources/customizations/.github/skills/policy-audit-template-usage/SKILL.md +48 -0
- package/resources/customizations/.github/skills/policy-compliance-order/SKILL.md +37 -0
- package/resources/customizations/.github/skills/powershell-change-budget-router/SKILL.md +48 -0
- package/resources/customizations/.github/skills/powershell-orchestration-state-machine/SKILL.md +57 -0
- package/resources/customizations/.github/skills/pr-base-branch-merge-base/SKILL.md +55 -0
- package/resources/customizations/.github/skills/pr-context-artifacts/SKILL.md +29 -0
- package/resources/customizations/.github/skills/remediation-handoff-atomic-planner/SKILL.md +39 -0
- package/resources/customizations/.github/skills/skill-canonical-location-audit/SKILL.md +48 -0
- package/resources/feature-templates/bug/plan.yyyy-MM-ddTHH-mm.md +44 -0
- package/resources/feature-templates/bug/potential_bug.md +59 -0
- package/resources/feature-templates/bug/spec.md +99 -0
- package/resources/feature-templates/epic/initiative.md +43 -0
- package/resources/feature-templates/feature/plan.yyyy-MM-ddTHH-mm.md +53 -0
- package/resources/feature-templates/feature/spec.md +66 -0
- package/resources/feature-templates/feature/user-story.md +42 -0
- package/resources/feature-templates/potential/template.md +33 -0
- package/resources/feature-templates/refactor/plan.yyyy-MM-ddTHH-mm.md +52 -0
- package/resources/feature-templates/refactor/spec.md +69 -0
- package/resources/powershell/PoshQC/PoshQC.Analyzer.psm1 +254 -0
- package/resources/powershell/PoshQC/PoshQC.FileDiscovery.psm1 +138 -0
- package/resources/powershell/PoshQC/PoshQC.Testing.psm1 +409 -0
- package/resources/powershell/PoshQC/PoshQC.psd1 +31 -0
- package/resources/powershell/PoshQC/PoshQC.psm1 +101 -0
- package/resources/powershell/PoshQC/README.md +80 -0
- package/resources/powershell/PoshQC/settings/pester.runsettings.psd1 +59 -0
- package/resources/powershell/PoshQC/settings/pssa.settings.psd1 +55 -0
- package/resources/scripts/dev_tools/__init__.py +0 -0
- package/resources/scripts/dev_tools/agentic_sync.py +819 -0
- package/resources/scripts/dev_tools/codex_native_converter/__init__.py +11 -0
- package/resources/scripts/dev_tools/codex_native_converter/__main__.py +6 -0
- package/resources/scripts/dev_tools/codex_native_converter/cli.py +11 -0
- package/resources/scripts/dev_tools/new_active_feature_folder.py +79 -0
- package/resources/scripts/dev_tools/new_active_feature_folder_docs.py +268 -0
- package/resources/scripts/dev_tools/new_active_feature_folder_flow.py +366 -0
- package/resources/scripts/dev_tools/new_active_feature_folder_io.py +306 -0
- package/resources/scripts/dev_tools/new_active_feature_folder_markdown.py +252 -0
- package/resources/scripts/dev_tools/new_active_feature_folder_models.py +136 -0
- package/resources/scripts/dev_tools/new_potential_bug_entry.py +465 -0
- package/resources/scripts/dev_tools/potential_to_issue.py +421 -0
- package/resources/scripts/dev_tools/potential_to_issue_content.py +212 -0
- package/resources/scripts/dev_tools/pr_context/__init__.py +0 -0
- package/resources/scripts/dev_tools/pr_context/collector.py +619 -0
- package/resources/scripts/dev_tools/pr_context/feature_docs.py +349 -0
- package/resources/scripts/dev_tools/pr_context/git.py +153 -0
- package/resources/scripts/dev_tools/pr_context/github.py +549 -0
- package/resources/scripts/dev_tools/pr_context/models.py +198 -0
- package/resources/scripts/dev_tools/pr_context/render.py +342 -0
- package/resources/scripts/dev_tools/pr_context/render_feature_excerpts.py +256 -0
- package/resources/scripts/dev_tools/pr_context/render_pr_helpers.py +291 -0
- package/resources/scripts/dev_tools/pr_context/summary_helpers.py +386 -0
- package/resources/scripts/dev_tools/pr_context/verification_evidence.py +171 -0
- package/resources/scripts/dev_tools/prompt_mode_contract.py +152 -0
- package/resources/scripts/dev_tools/push_down_claude_customizations.py +188 -0
- package/resources/scripts/dev_tools/push_down_codex_and_agents_customizations.py +139 -0
- package/resources/scripts/dev_tools/push_down_copilot_customizations.py +504 -0
- package/resources/scripts/dev_tools/push_down_copilot_customizations_filesystem.py +217 -0
- package/resources/scripts/dev_tools/push_down_copilot_customizations_rewrites.py +293 -0
- package/resources/scripts/dev_tools/resolve_file_prompt.py +457 -0
- package/resources/scripts/dev_tools/resolve_hard_lock_prompt.py +444 -0
- package/resources/scripts/dev_tools/validate_orchestration_artifacts.py +554 -0
- package/resources/templates/codex_native_converter.py +35 -0
- package/resources/templates/collect_commit_context.py +212 -0
- package/resources/templates/collect_pr_context.py +74 -0
- package/resources/templates/hello_pwsh.ps1 +3 -0
- package/resources/templates/hello_python.py +11 -0
- package/resources/templates/link-parent-child.ps1 +480 -0
- package/resources/templates/new-claude-worktree-session.ps1 +232 -0
- package/resources/templates/new-potential-entry.ps1 +187 -0
- package/resources/templates/new_active_feature_folder.py +67 -0
- package/resources/templates/new_potential_bug_entry.py +54 -0
- package/resources/templates/policy_audit/AGENTS.md +117 -0
- package/resources/templates/policy_audit/code-review.yyyy-MM-ddTHH-mm.md +165 -0
- package/resources/templates/policy_audit/feature-audit.yyyy-MM-ddTHH-mm.md +124 -0
- package/resources/templates/policy_audit/policy-audit.yyyy-MM-ddTHH-mm.md +649 -0
- package/resources/templates/potential_to_issue.py +55 -0
- package/resources/templates/push_down_claude_customizations.py +188 -0
- package/resources/templates/push_down_codex_and_agents_customizations.py +95 -0
- package/resources/templates/push_down_copilot_customizations.py +124 -0
- package/resources/templates/resolve_atomic_plan_prompt.py +75 -0
- package/resources/templates/resolve_hard_lock_prompt.py +65 -0
- package/resources/templates/run-poshqc-analyze-autofix.ps1 +16 -0
- package/resources/templates/run-poshqc-analyze.ps1 +26 -0
- package/resources/templates/run-poshqc-format.ps1 +26 -0
- package/resources/templates/run-poshqc-suite.ps1 +24 -0
- package/resources/templates/run-poshqc-test.ps1 +32 -0
- package/resources/templates/sync-agents-from-instructions.ps1 +400 -0
- package/resources/templates/validate_orchestration_artifacts.py +55 -0
- package/resources/templates/vscode-cli.helpers.ps1 +63 -0
|
@@ -0,0 +1,384 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
set -euo pipefail
|
|
3
|
+
|
|
4
|
+
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
5
|
+
REPO_ROOT="$(cd "${SCRIPT_DIR}/.." && pwd)"
|
|
6
|
+
|
|
7
|
+
# Codex Web copies this script to /tmp before running it, so the script-relative
|
|
8
|
+
# REPO_ROOT resolves to / rather than the actual checkout. Fall back to the
|
|
9
|
+
# working directory, which Codex sets to the repo root.
|
|
10
|
+
if [ ! -f "${REPO_ROOT}/TaskMaster.sln" ]; then
|
|
11
|
+
REPO_ROOT="$(pwd)"
|
|
12
|
+
fi
|
|
13
|
+
|
|
14
|
+
log() {
|
|
15
|
+
printf '[codex-web-setup] %s\n' "$*"
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
fail() {
|
|
19
|
+
printf '[codex-web-setup] error: %s\n' "$*" >&2
|
|
20
|
+
exit 1
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
warn() {
|
|
24
|
+
printf '[codex-web-setup] warning: %s\n' "$*" >&2
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
read_global_json_sdk_version() {
|
|
28
|
+
local global_json_path="${REPO_ROOT}/global.json"
|
|
29
|
+
|
|
30
|
+
if [ ! -f "${global_json_path}" ]; then
|
|
31
|
+
return 1
|
|
32
|
+
fi
|
|
33
|
+
|
|
34
|
+
grep -oE '"version"[[:space:]]*:[[:space:]]*"[^"]+"' "${global_json_path}" |
|
|
35
|
+
head -n 1 |
|
|
36
|
+
sed -E 's/.*"version"[[:space:]]*:[[:space:]]*"([^"]+)".*/\1/'
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
append_if_missing() {
|
|
40
|
+
local file="$1"
|
|
41
|
+
local line="$2"
|
|
42
|
+
|
|
43
|
+
touch "$file"
|
|
44
|
+
if ! grep -Fqx "$line" "$file"; then
|
|
45
|
+
printf '%s\n' "$line" >>"$file"
|
|
46
|
+
fi
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
install_apt_packages() {
|
|
50
|
+
if ! command -v apt-get >/dev/null 2>&1; then
|
|
51
|
+
warn "apt-get is unavailable; skipping OS package installation."
|
|
52
|
+
return
|
|
53
|
+
fi
|
|
54
|
+
|
|
55
|
+
local runner=""
|
|
56
|
+
if [ "$(id -u)" -eq 0 ]; then
|
|
57
|
+
runner=""
|
|
58
|
+
elif command -v sudo >/dev/null 2>&1; then
|
|
59
|
+
runner="sudo"
|
|
60
|
+
else
|
|
61
|
+
warn "apt-get requires root and sudo is unavailable; skipping OS package installation."
|
|
62
|
+
return
|
|
63
|
+
fi
|
|
64
|
+
|
|
65
|
+
log "Installing Codex Web dependencies with apt-get..."
|
|
66
|
+
${runner} apt-get update
|
|
67
|
+
${runner} apt-get install -y \
|
|
68
|
+
ca-certificates \
|
|
69
|
+
curl \
|
|
70
|
+
git \
|
|
71
|
+
jq \
|
|
72
|
+
lsb-release \
|
|
73
|
+
mono-complete \
|
|
74
|
+
ripgrep \
|
|
75
|
+
unzip \
|
|
76
|
+
zip
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
install_powershell() {
|
|
80
|
+
if command -v pwsh >/dev/null 2>&1; then
|
|
81
|
+
log "PowerShell is already available; skipping."
|
|
82
|
+
return
|
|
83
|
+
fi
|
|
84
|
+
|
|
85
|
+
if ! command -v apt-get >/dev/null 2>&1; then
|
|
86
|
+
warn "apt-get is unavailable; skipping PowerShell installation."
|
|
87
|
+
return
|
|
88
|
+
fi
|
|
89
|
+
|
|
90
|
+
local runner=""
|
|
91
|
+
if [ "$(id -u)" -ne 0 ]; then
|
|
92
|
+
if command -v sudo >/dev/null 2>&1; then
|
|
93
|
+
runner="sudo"
|
|
94
|
+
else
|
|
95
|
+
warn "PowerShell installation requires root; skipping."
|
|
96
|
+
return
|
|
97
|
+
fi
|
|
98
|
+
fi
|
|
99
|
+
|
|
100
|
+
local ubuntu_version
|
|
101
|
+
ubuntu_version="$(lsb_release -rs 2>/dev/null || echo '24.04')"
|
|
102
|
+
|
|
103
|
+
log "Registering Microsoft package repository for PowerShell (Ubuntu ${ubuntu_version})..."
|
|
104
|
+
local ms_pkg
|
|
105
|
+
ms_pkg="$(mktemp --suffix=.deb)"
|
|
106
|
+
if curl -fsSL "https://packages.microsoft.com/config/ubuntu/${ubuntu_version}/packages-microsoft-prod.deb" -o "${ms_pkg}"; then
|
|
107
|
+
${runner} dpkg -i "${ms_pkg}" || true
|
|
108
|
+
rm -f "${ms_pkg}"
|
|
109
|
+
${runner} apt-get update
|
|
110
|
+
${runner} apt-get install -y powershell
|
|
111
|
+
else
|
|
112
|
+
rm -f "${ms_pkg}"
|
|
113
|
+
warn "Could not download Microsoft package repo; skipping PowerShell installation."
|
|
114
|
+
fi
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
install_nuget() {
|
|
118
|
+
if command -v nuget >/dev/null 2>&1; then
|
|
119
|
+
log "nuget is already available; skipping."
|
|
120
|
+
return
|
|
121
|
+
fi
|
|
122
|
+
|
|
123
|
+
if ! command -v mono >/dev/null 2>&1; then
|
|
124
|
+
warn "mono is unavailable; cannot install nuget wrapper."
|
|
125
|
+
return
|
|
126
|
+
fi
|
|
127
|
+
|
|
128
|
+
log "Downloading nuget.exe and creating mono wrapper..."
|
|
129
|
+
local nuget_exe="/usr/local/bin/nuget.exe"
|
|
130
|
+
local nuget_wrapper="/usr/local/bin/nuget"
|
|
131
|
+
|
|
132
|
+
local runner=""
|
|
133
|
+
if [ "$(id -u)" -ne 0 ]; then
|
|
134
|
+
runner="sudo"
|
|
135
|
+
fi
|
|
136
|
+
|
|
137
|
+
if curl -fsSL "https://dist.nuget.org/win-x86-commandline/latest/nuget.exe" -o "${nuget_exe}"; then
|
|
138
|
+
printf '#!/usr/bin/env bash\nexec mono %s "$@"\n' "${nuget_exe}" | ${runner} tee "${nuget_wrapper}" >/dev/null
|
|
139
|
+
${runner} chmod +x "${nuget_wrapper}"
|
|
140
|
+
log "nuget wrapper installed at ${nuget_wrapper}."
|
|
141
|
+
else
|
|
142
|
+
warn "Could not download nuget.exe; skipping."
|
|
143
|
+
fi
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
install_dotnet_sdk() {
|
|
147
|
+
local dotnet_root="${REPO_ROOT}/.dotnet-sdk"
|
|
148
|
+
local dotnet_version=""
|
|
149
|
+
local install_script=""
|
|
150
|
+
|
|
151
|
+
dotnet_version="$(read_global_json_sdk_version || true)"
|
|
152
|
+
if [ -z "${dotnet_version}" ]; then
|
|
153
|
+
warn "Could not read the SDK version from global.json; skipping repo-local .NET SDK installation."
|
|
154
|
+
return
|
|
155
|
+
fi
|
|
156
|
+
|
|
157
|
+
if [ -x "${dotnet_root}/dotnet" ] && [ -d "${dotnet_root}/sdk/${dotnet_version}" ]; then
|
|
158
|
+
log "Repo-local .NET SDK ${dotnet_version} is already available at ${dotnet_root}."
|
|
159
|
+
else
|
|
160
|
+
log "Installing repo-local .NET SDK ${dotnet_version} into ${dotnet_root}..."
|
|
161
|
+
install_script="$(mktemp)"
|
|
162
|
+
curl -fsSL https://dot.net/v1/dotnet-install.sh -o "${install_script}"
|
|
163
|
+
bash "${install_script}" --version "${dotnet_version}" --install-dir "${dotnet_root}"
|
|
164
|
+
rm -f "${install_script}"
|
|
165
|
+
fi
|
|
166
|
+
|
|
167
|
+
export DOTNET_ROOT="${dotnet_root}"
|
|
168
|
+
export PATH="${dotnet_root}:${PATH}"
|
|
169
|
+
|
|
170
|
+
append_if_missing "${HOME}/.bashrc" "export DOTNET_ROOT=\"${dotnet_root}\""
|
|
171
|
+
append_if_missing "${HOME}/.bashrc" "export PATH=\"${dotnet_root}:\$PATH\""
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
install_dotnet_tools() {
|
|
175
|
+
if ! command -v dotnet >/dev/null 2>&1; then
|
|
176
|
+
fail "dotnet is unavailable; cannot restore the required dotnet tool manifest."
|
|
177
|
+
fi
|
|
178
|
+
|
|
179
|
+
if [ ! -f "${REPO_ROOT}/dotnet-tools.json" ]; then
|
|
180
|
+
fail "Required dotnet tool manifest not found at ${REPO_ROOT}/dotnet-tools.json."
|
|
181
|
+
fi
|
|
182
|
+
|
|
183
|
+
log "Restoring repo-local dotnet tools from dotnet-tools.json..."
|
|
184
|
+
(
|
|
185
|
+
cd "${REPO_ROOT}"
|
|
186
|
+
dotnet tool restore --tool-manifest "${REPO_ROOT}/dotnet-tools.json"
|
|
187
|
+
)
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
install_dotnet_coverage() {
|
|
191
|
+
if ! command -v dotnet >/dev/null 2>&1; then
|
|
192
|
+
fail "dotnet is unavailable; cannot install dotnet-coverage."
|
|
193
|
+
fi
|
|
194
|
+
|
|
195
|
+
local dotnet_tools_dir="${HOME}/.dotnet/tools"
|
|
196
|
+
mkdir -p "${dotnet_tools_dir}"
|
|
197
|
+
|
|
198
|
+
export PATH="${dotnet_tools_dir}:${PATH}"
|
|
199
|
+
append_if_missing "${HOME}/.bashrc" "export PATH=\"\$HOME/.dotnet/tools:\$PATH\""
|
|
200
|
+
|
|
201
|
+
if command -v dotnet-coverage >/dev/null 2>&1; then
|
|
202
|
+
log "dotnet-coverage is already available; skipping."
|
|
203
|
+
return
|
|
204
|
+
fi
|
|
205
|
+
|
|
206
|
+
log "Installing dotnet-coverage as a global dotnet tool..."
|
|
207
|
+
if dotnet tool list --global | grep -Eq '^dotnet-coverage\s'; then
|
|
208
|
+
dotnet tool update --global dotnet-coverage
|
|
209
|
+
else
|
|
210
|
+
dotnet tool install --global dotnet-coverage
|
|
211
|
+
fi
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
install_actionlint() {
|
|
215
|
+
if command -v actionlint >/dev/null 2>&1; then
|
|
216
|
+
log "actionlint is already available; skipping."
|
|
217
|
+
return
|
|
218
|
+
fi
|
|
219
|
+
|
|
220
|
+
if ! command -v tar >/dev/null 2>&1; then
|
|
221
|
+
warn "tar is unavailable; skipping actionlint installation."
|
|
222
|
+
return
|
|
223
|
+
fi
|
|
224
|
+
|
|
225
|
+
local actionlint_version="1.7.7"
|
|
226
|
+
local temp_dir=""
|
|
227
|
+
local runner=""
|
|
228
|
+
|
|
229
|
+
if [ "$(id -u)" -ne 0 ]; then
|
|
230
|
+
if command -v sudo >/dev/null 2>&1; then
|
|
231
|
+
runner="sudo"
|
|
232
|
+
else
|
|
233
|
+
warn "actionlint installation requires root or sudo; skipping."
|
|
234
|
+
return
|
|
235
|
+
fi
|
|
236
|
+
fi
|
|
237
|
+
|
|
238
|
+
temp_dir="$(mktemp -d)"
|
|
239
|
+
log "Installing actionlint v${actionlint_version}..."
|
|
240
|
+
if curl -fsSL "https://github.com/rhysd/actionlint/releases/download/v${actionlint_version}/actionlint_${actionlint_version}_linux_amd64.tar.gz" -o "${temp_dir}/actionlint.tar.gz"; then
|
|
241
|
+
tar -xzf "${temp_dir}/actionlint.tar.gz" -C "${temp_dir}" actionlint
|
|
242
|
+
${runner} install -m 0755 "${temp_dir}/actionlint" /usr/local/bin/actionlint
|
|
243
|
+
log "actionlint installed at /usr/local/bin/actionlint."
|
|
244
|
+
else
|
|
245
|
+
warn "Could not download actionlint; skipping."
|
|
246
|
+
fi
|
|
247
|
+
|
|
248
|
+
rm -rf "${temp_dir}"
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
restore_packages_if_needed() {
|
|
252
|
+
cd "${REPO_ROOT}"
|
|
253
|
+
|
|
254
|
+
if [ -d "${REPO_ROOT}/packages" ] && [ -n "$(find "${REPO_ROOT}/packages" -mindepth 1 -maxdepth 1 -print -quit)" ]; then
|
|
255
|
+
log "packages/ is already populated; skipping restore."
|
|
256
|
+
return
|
|
257
|
+
fi
|
|
258
|
+
|
|
259
|
+
if ! command -v nuget >/dev/null 2>&1; then
|
|
260
|
+
warn "nuget is unavailable; cannot restore packages.config dependencies."
|
|
261
|
+
return
|
|
262
|
+
fi
|
|
263
|
+
|
|
264
|
+
log "Restoring solution packages into packages/..."
|
|
265
|
+
nuget restore "${REPO_ROOT}/TaskMaster.sln" -PackagesDirectory "${REPO_ROOT}/packages"
|
|
266
|
+
}
|
|
267
|
+
|
|
268
|
+
verify_formatting_capability() {
|
|
269
|
+
log "Verifying formatting capability..."
|
|
270
|
+
|
|
271
|
+
command -v dotnet >/dev/null 2>&1 || fail "dotnet is not available after setup."
|
|
272
|
+
command -v pwsh >/dev/null 2>&1 || fail "pwsh is not available after setup."
|
|
273
|
+
|
|
274
|
+
(
|
|
275
|
+
cd "${REPO_ROOT}"
|
|
276
|
+
dotnet tool run csharpier --version >/dev/null
|
|
277
|
+
) || fail "CSharpier is not runnable via 'dotnet tool run csharpier'."
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
is_windows_powershell_host() {
|
|
281
|
+
pwsh -NoProfile -ExecutionPolicy Bypass -Command "& { if (\$IsWindows) { exit 0 } ; exit 1 }" >/dev/null 2>&1
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
verify_windows_visual_studio_task_capability() {
|
|
285
|
+
pwsh -NoProfile -ExecutionPolicy Bypass -File "${REPO_ROOT}/scripts/vscode/Invoke-VSBuild.ps1" -SolutionPath TaskMaster.sln -Configuration Debug -Platform 'Any CPU' -NoExecute >/dev/null || fail "MSBuild tooling required by the restore/build/lint/type-check tasks is unavailable."
|
|
286
|
+
|
|
287
|
+
pwsh -NoProfile -ExecutionPolicy Bypass -Command "& {
|
|
288
|
+
\$vswherePath = Join-Path \${env:ProgramFiles(x86)} 'Microsoft Visual Studio\Installer\vswhere.exe'
|
|
289
|
+
if (-not (Test-Path \$vswherePath)) {
|
|
290
|
+
throw 'vswhere.exe was not found. Install Visual Studio 2022 (or Build Tools) with Test Platform components.'
|
|
291
|
+
}
|
|
292
|
+
|
|
293
|
+
\$vstestPath = & \$vswherePath -latest -products * -find 'Common7\IDE\Extensions\TestPlatform\vstest.console.exe' | Select-Object -First 1
|
|
294
|
+
if (-not \$vstestPath) {
|
|
295
|
+
throw 'vstest.console.exe not found via vswhere. Install Visual Studio Test Platform components.'
|
|
296
|
+
}
|
|
297
|
+
}" >/dev/null || fail "Visual Studio test tooling required by the MSTest tasks is unavailable."
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
verify_build_and_test_capability() {
|
|
301
|
+
log "Verifying restore/build/lint/type-check/test capability..."
|
|
302
|
+
|
|
303
|
+
command -v pwsh >/dev/null 2>&1 || fail "pwsh is not available after setup."
|
|
304
|
+
command -v dotnet-coverage >/dev/null 2>&1 || fail "dotnet-coverage is not available after setup."
|
|
305
|
+
[ -f "${REPO_ROOT}/coverage.config" ] || fail "coverage.config is missing from the repository root."
|
|
306
|
+
|
|
307
|
+
if ! is_windows_powershell_host; then
|
|
308
|
+
warn "Skipping Windows-only Visual Studio task verification because this host is not Windows. Restore/build/test parity still requires Windows plus Visual Studio tooling discoverable via vswhere.exe."
|
|
309
|
+
return
|
|
310
|
+
fi
|
|
311
|
+
|
|
312
|
+
verify_windows_visual_studio_task_capability
|
|
313
|
+
}
|
|
314
|
+
|
|
315
|
+
verify_required_task_tooling() {
|
|
316
|
+
verify_formatting_capability
|
|
317
|
+
verify_build_and_test_capability
|
|
318
|
+
}
|
|
319
|
+
|
|
320
|
+
write_repo_notes() {
|
|
321
|
+
cat <<'EOF'
|
|
322
|
+
|
|
323
|
+
Workspace profile detected:
|
|
324
|
+
- Legacy Visual Studio solution targeting .NET Framework 4.8.1
|
|
325
|
+
- Repo-pinned .NET SDK via global.json with install path rooted at .dotnet-sdk/
|
|
326
|
+
- Local dotnet tool manifest for CSharpier
|
|
327
|
+
- Global dotnet-coverage installation for MSTest coverage collection
|
|
328
|
+
- Windows-first build/test scripts that rely on VS tools such as vswhere, MSBuild.exe, and vstest.console.exe
|
|
329
|
+
- Outlook interop and VSTO references across the main add-in and supporting libraries
|
|
330
|
+
|
|
331
|
+
Codex Web caveat:
|
|
332
|
+
- This script verifies general Codex Web prerequisites everywhere, and it verifies the full Visual Studio task chain only on Windows hosts.
|
|
333
|
+
- In Linux-based Codex Web, the script completes with a warning after skipping the Windows-only Visual Studio checks because the restore/build/test tasks require Windows plus Visual Studio 2022 or Build Tools components discoverable through vswhere.exe.
|
|
334
|
+
- Full add-in build/debug parity still requires Windows with Visual Studio 2022, Office/VSTO tooling, and Outlook desktop.
|
|
335
|
+
|
|
336
|
+
Useful follow-up commands after a successful setup run:
|
|
337
|
+
- source ~/.bashrc
|
|
338
|
+
- dotnet --info
|
|
339
|
+
- dotnet tool run csharpier format .
|
|
340
|
+
- pwsh -NoProfile -ExecutionPolicy Bypass -File scripts/vscode/Invoke-Restore.ps1 -SolutionPath TaskMaster.sln -Configuration Debug -Platform "Any CPU"
|
|
341
|
+
- pwsh -NoProfile -ExecutionPolicy Bypass -File scripts/vscode/Invoke-VSBuild.ps1 -SolutionPath TaskMaster.sln -Configuration Debug -Platform "Any CPU" -EnableNETAnalyzers -EnforceCodeStyleInBuild
|
|
342
|
+
- pwsh -NoProfile -ExecutionPolicy Bypass -File scripts/vscode/Invoke-VSBuild.ps1 -SolutionPath TaskMaster.sln -Configuration Debug -Platform "Any CPU" -EnableNullable -TreatWarningsAsErrors
|
|
343
|
+
- pwsh -NoProfile -ExecutionPolicy Bypass -File scripts/vscode/Invoke-MSTest.ps1 -SearchRoot . -Configuration Debug
|
|
344
|
+
- pwsh -NoProfile -ExecutionPolicy Bypass -File scripts/vscode/Invoke-MSTestWithCoverage.ps1 -SearchRoot . -Configuration Debug
|
|
345
|
+
|
|
346
|
+
Note:
|
|
347
|
+
- The repo's existing PowerShell helper scripts under scripts/vscode/ are Windows/Visual Studio oriented by design, so Linux-based Codex Web setup can prepare only a partial toolchain.
|
|
348
|
+
EOF
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
main() {
|
|
352
|
+
log "Bootstrapping a Codex Web environment for ${REPO_ROOT}"
|
|
353
|
+
|
|
354
|
+
export CI=true
|
|
355
|
+
export DOTNET_CLI_TELEMETRY_OPTOUT=1
|
|
356
|
+
export DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
|
|
357
|
+
export DOTNET_MULTILEVEL_LOOKUP=0
|
|
358
|
+
export NUGET_XMLDOC_MODE=skip
|
|
359
|
+
|
|
360
|
+
append_if_missing "${HOME}/.bashrc" 'export CI=true'
|
|
361
|
+
append_if_missing "${HOME}/.bashrc" 'export DOTNET_CLI_TELEMETRY_OPTOUT=1'
|
|
362
|
+
append_if_missing "${HOME}/.bashrc" 'export DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1'
|
|
363
|
+
append_if_missing "${HOME}/.bashrc" 'export DOTNET_MULTILEVEL_LOOKUP=0'
|
|
364
|
+
append_if_missing "${HOME}/.bashrc" 'export NUGET_XMLDOC_MODE=skip'
|
|
365
|
+
|
|
366
|
+
install_apt_packages
|
|
367
|
+
install_powershell
|
|
368
|
+
install_nuget
|
|
369
|
+
install_dotnet_sdk
|
|
370
|
+
install_dotnet_tools
|
|
371
|
+
install_dotnet_coverage
|
|
372
|
+
verify_required_task_tooling
|
|
373
|
+
install_actionlint
|
|
374
|
+
restore_packages_if_needed
|
|
375
|
+
|
|
376
|
+
if command -v git >/dev/null 2>&1; then
|
|
377
|
+
git config --global core.autocrlf input || true
|
|
378
|
+
fi
|
|
379
|
+
|
|
380
|
+
write_repo_notes
|
|
381
|
+
log "Setup complete."
|
|
382
|
+
}
|
|
383
|
+
|
|
384
|
+
main "$@"
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
# Review and merge native MCP, hook, and approval settings intentionally.
|
|
2
|
+
|
|
3
|
+
{
|
|
4
|
+
"$schema": "https://json.schemastore.org/claude-code-settings.json",
|
|
5
|
+
"agent": "orchestrator",
|
|
6
|
+
"permissions": {
|
|
7
|
+
"allow": [
|
|
8
|
+
"Bash(git *)",
|
|
9
|
+
"Bash(poetry run *)",
|
|
10
|
+
"Bash(pwsh *)",
|
|
11
|
+
"Read",
|
|
12
|
+
"Edit(/docs/**)",
|
|
13
|
+
"Write(/docs/**)",
|
|
14
|
+
"Write(/artifacts/**)",
|
|
15
|
+
"mcp__drmCopilotExtension__run_poshqc_format",
|
|
16
|
+
"mcp__drmCopilotExtension__run_poshqc_analyze",
|
|
17
|
+
"mcp__drmCopilotExtension__run_poshqc_test",
|
|
18
|
+
"mcp__drmCopilotExtension__run_poshqc_analyze_autofix",
|
|
19
|
+
"mcp__drmCopilotExtension__resolve_execute_hard_lock_prompt",
|
|
20
|
+
"mcp__drmCopilotExtension__collect_pr_context",
|
|
21
|
+
"mcp__drmCopilotExtension__new_potential_entry",
|
|
22
|
+
"mcp__drmCopilotExtension__new_potential_bug_entry",
|
|
23
|
+
"mcp__drmCopilotExtension__potential_to_issue",
|
|
24
|
+
"mcp__drmCopilotExtension__new_active_feature_folder",
|
|
25
|
+
"mcp__drmCopilotExtension__validate_orchestration_artifacts",
|
|
26
|
+
"mcp__drmCopilotExtension__resolve_atomic_plan_prompt",
|
|
27
|
+
"Agent(atomic-planner)",
|
|
28
|
+
"Agent(atomic-executor)",
|
|
29
|
+
"Agent(feature-review)",
|
|
30
|
+
"Agent(task-researcher)",
|
|
31
|
+
"Agent(prd-feature)",
|
|
32
|
+
"Agent(staged-review)",
|
|
33
|
+
"Agent(epic-review)",
|
|
34
|
+
"Agent(status-updater)",
|
|
35
|
+
"Agent(python-typed-engineer)",
|
|
36
|
+
"Agent(powershell-typed-engineer)",
|
|
37
|
+
"Agent(csharp-typed-engineer)",
|
|
38
|
+
"Agent(typescript-engineer)",
|
|
39
|
+
"Skill(orchestrate *)",
|
|
40
|
+
"Skill(commit-message *)",
|
|
41
|
+
"Skill(pr-author *)",
|
|
42
|
+
"Skill(research-issue *)",
|
|
43
|
+
"Skill(review-feature *)",
|
|
44
|
+
"Skill(review-staged *)",
|
|
45
|
+
"Skill(review-epic *)",
|
|
46
|
+
"Skill(update-status *)",
|
|
47
|
+
"Skill(fill-feature-docs *)",
|
|
48
|
+
"Skill(python-change-budget-router *)",
|
|
49
|
+
"Skill(python-qa-gate *)",
|
|
50
|
+
"Skill(invoke-python-engineer *)",
|
|
51
|
+
"Skill(powershell-change-budget-router *)",
|
|
52
|
+
"Skill(powershell-qa-gate *)",
|
|
53
|
+
"Skill(invoke-powershell-engineer *)",
|
|
54
|
+
"Skill(translate-copilot-to-claude *)",
|
|
55
|
+
"Skill(execute-hard-lock *)",
|
|
56
|
+
"Edit(/.agents/skills/execute-hard-lock/**)",
|
|
57
|
+
"Edit(/.agents/skills/feature-review-workflow/**)",
|
|
58
|
+
"Edit(/.agents/skills/csharp-qa-gate/**)"
|
|
59
|
+
],
|
|
60
|
+
"deny": [
|
|
61
|
+
"Read(./.env)",
|
|
62
|
+
"Read(./.env.*)",
|
|
63
|
+
"Read(./secrets/**)",
|
|
64
|
+
"Edit(./secrets/**)",
|
|
65
|
+
"Write(./secrets/**)"
|
|
66
|
+
],
|
|
67
|
+
"additionalDirectories": [
|
|
68
|
+
"c:\\Users\\DanMoisan\\repos\\drm-copilot\\.claude\\skills\\execute-hard-lock"
|
|
69
|
+
]
|
|
70
|
+
},
|
|
71
|
+
"hooks": {
|
|
72
|
+
"PreToolUse": [
|
|
73
|
+
{
|
|
74
|
+
"matcher": "Bash",
|
|
75
|
+
"hooks": [
|
|
76
|
+
{
|
|
77
|
+
"type": "command",
|
|
78
|
+
"command": "pwsh -NoProfile -File .codex/hooks/validate-bash.ps1"
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
"type": "command",
|
|
82
|
+
"command": "pwsh -NoProfile -File .codex/hooks/enforce-promotion-mcp-only.ps1"
|
|
83
|
+
}
|
|
84
|
+
]
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
"matcher": "Write|Edit",
|
|
88
|
+
"hooks": [
|
|
89
|
+
{
|
|
90
|
+
"type": "command",
|
|
91
|
+
"command": "pwsh -NoProfile -File .codex/hooks/check-python-test-purity.ps1"
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
"type": "command",
|
|
95
|
+
"command": "pwsh -NoProfile -File .codex/hooks/enforce-python-batch-budget.ps1"
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
"type": "command",
|
|
99
|
+
"command": "pwsh -NoProfile -File .codex/hooks/check-powershell-test-purity.ps1"
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
"type": "command",
|
|
103
|
+
"command": "pwsh -NoProfile -File .codex/hooks/enforce-powershell-batch-budget.ps1"
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
"type": "command",
|
|
107
|
+
"command": "pwsh -NoProfile -File .codex/hooks/enforce-evidence-locations.ps1"
|
|
108
|
+
}
|
|
109
|
+
]
|
|
110
|
+
}
|
|
111
|
+
],
|
|
112
|
+
"SubagentStop": [
|
|
113
|
+
{
|
|
114
|
+
"matcher": "atomic-planner|atomic-executor|feature-review|task-researcher|prd-feature|staged-review|epic-review|status-updater|python-typed-engineer|powershell-typed-engineer|csharp-typed-engineer|typescript-engineer",
|
|
115
|
+
"hooks": [
|
|
116
|
+
{
|
|
117
|
+
"type": "command",
|
|
118
|
+
"command": "pwsh -NoProfile -Command \"$input = $env:CLAUDE_HOOK_INPUT | ConvertFrom-Json; $output = $input.output; if (-not ($output -match '(plan-path|research-path|review-artifact|PREFLIGHT|evidence/)')) { Write-Error 'Subagent stopped without required completion artifact path'; exit 1 }; exit 0\""
|
|
119
|
+
}
|
|
120
|
+
]
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
"matcher": "feature-review",
|
|
124
|
+
"hooks": [
|
|
125
|
+
{
|
|
126
|
+
"type": "command",
|
|
127
|
+
"command": "pwsh -NoProfile -File .codex/hooks/validate-feature-review-coverage.ps1"
|
|
128
|
+
}
|
|
129
|
+
]
|
|
130
|
+
}
|
|
131
|
+
]
|
|
132
|
+
},
|
|
133
|
+
"enabledPlugins": {
|
|
134
|
+
"skill-creator@claude-plugins-official": true
|
|
135
|
+
},
|
|
136
|
+
"defaultPermissionMode": "bypassPermissions"
|
|
137
|
+
}
|
package/resources/codex-and-agents-customizations/.codex/hooks/check-powershell-test-purity.ps1
ADDED
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
# Converted hook
|
|
2
|
+
# Review the generated hook behavior before enabling it.
|
|
3
|
+
|
|
4
|
+
<#
|
|
5
|
+
.SYNOPSIS
|
|
6
|
+
Pre-tool-use hook for Claude Code that blocks forbidden patterns in PowerShell unit tests.
|
|
7
|
+
|
|
8
|
+
.DESCRIPTION
|
|
9
|
+
This script is invoked by the Claude Code PreToolUse hook before any Write or Edit
|
|
10
|
+
operation on a file path matching a Pester test file (*.Tests.ps1 or tests/**/*.ps1).
|
|
11
|
+
It reads the tool input from the CLAUDE_TOOL_INPUT environment variable (JSON with
|
|
12
|
+
'file_path' and a content field: 'content' for Write, 'new_string' for Edit) and
|
|
13
|
+
rejects the operation when the proposed content introduces forbidden runtime
|
|
14
|
+
dependencies or violates the mocking rules.
|
|
15
|
+
|
|
16
|
+
Forbidden patterns in Pester unit tests include:
|
|
17
|
+
- direct external-executable mocking (Mock git, Mock gh, Mock actionlint, etc.)
|
|
18
|
+
instead of mocking the wrapper function (Invoke-GitExe, Invoke-GhExe, etc.)
|
|
19
|
+
- temporary filesystem usage (New-TemporaryFile, [System.IO.Path]::GetTempFileName,
|
|
20
|
+
[System.IO.Path]::GetTempPath, $env:TEMP usage, $env:TMP usage)
|
|
21
|
+
- network access (Invoke-WebRequest, Invoke-RestMethod, System.Net.Http.*,
|
|
22
|
+
System.Net.WebRequest, System.Net.Sockets)
|
|
23
|
+
- subprocess execution (Start-Process with raw executables)
|
|
24
|
+
- time-based flakiness (Start-Sleep)
|
|
25
|
+
|
|
26
|
+
If the content contains any forbidden pattern, the script writes a JSON response
|
|
27
|
+
to stdout with 'decision': 'block' and exits with code 0 to let Claude Code surface
|
|
28
|
+
the reason.
|
|
29
|
+
|
|
30
|
+
.NOTES
|
|
31
|
+
Compatible with PowerShell 7+.
|
|
32
|
+
This script must not modify any state; it is a read-only validation gate.
|
|
33
|
+
It only inspects tool inputs targeting Pester test paths; all other paths pass through.
|
|
34
|
+
#>
|
|
35
|
+
[CmdletBinding()]
|
|
36
|
+
param()
|
|
37
|
+
|
|
38
|
+
$toolInputRaw = $env:CLAUDE_TOOL_INPUT
|
|
39
|
+
if (-not $toolInputRaw) {
|
|
40
|
+
exit 0
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
try {
|
|
44
|
+
$toolInput = $toolInputRaw | ConvertFrom-Json -ErrorAction Stop
|
|
45
|
+
}
|
|
46
|
+
catch {
|
|
47
|
+
exit 0
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
$filePath = $toolInput.file_path
|
|
51
|
+
if (-not $filePath) {
|
|
52
|
+
exit 0
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
$normalized = $filePath -replace '\\', '/'
|
|
56
|
+
$isPowerShellTestFile = ($normalized -match '(^|/)tests/.*\.ps1$') -or ($normalized -match '\.Tests\.ps1$')
|
|
57
|
+
if (-not $isPowerShellTestFile) {
|
|
58
|
+
exit 0
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
$content = $null
|
|
62
|
+
if ($null -ne $toolInput.content) {
|
|
63
|
+
$content = [string]$toolInput.content
|
|
64
|
+
}
|
|
65
|
+
elseif ($null -ne $toolInput.new_string) {
|
|
66
|
+
$content = [string]$toolInput.new_string
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
if (-not $content) {
|
|
70
|
+
exit 0
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
$forbiddenPatterns = @(
|
|
74
|
+
@{ Pattern = '(?m)^\s*Mock\s+git\b'; Reason = 'direct Mock git forbidden in Pester tests; mock the Invoke-GitExe wrapper instead' },
|
|
75
|
+
@{ Pattern = '(?m)^\s*Mock\s+gh\b'; Reason = 'direct Mock gh forbidden in Pester tests; mock the Invoke-GhExe wrapper instead' },
|
|
76
|
+
@{ Pattern = '(?m)^\s*Mock\s+actionlint\b'; Reason = 'direct Mock actionlint forbidden in Pester tests; mock the Invoke-ActionlintExe wrapper instead' },
|
|
77
|
+
@{ Pattern = "(?m)^\s*Mock\s+['""]git['""]"; Reason = 'direct Mock ''git'' forbidden in Pester tests; mock the Invoke-GitExe wrapper instead' },
|
|
78
|
+
@{ Pattern = "(?m)^\s*Mock\s+['""]gh['""]"; Reason = 'direct Mock ''gh'' forbidden in Pester tests; mock the Invoke-GhExe wrapper instead' },
|
|
79
|
+
@{ Pattern = '\bNew-TemporaryFile\b'; Reason = 'New-TemporaryFile forbidden in Pester unit tests' },
|
|
80
|
+
@{ Pattern = '\[System\.IO\.Path\]::GetTempFileName'; Reason = 'temporary files forbidden in Pester unit tests' },
|
|
81
|
+
@{ Pattern = '\[System\.IO\.Path\]::GetTempPath'; Reason = 'temp path usage forbidden in Pester unit tests' },
|
|
82
|
+
@{ Pattern = '\$env:TEMP\b'; Reason = '$env:TEMP usage forbidden in Pester unit tests' },
|
|
83
|
+
@{ Pattern = '\$env:TMP\b'; Reason = '$env:TMP usage forbidden in Pester unit tests' },
|
|
84
|
+
@{ Pattern = '\bInvoke-WebRequest\b'; Reason = 'network access (Invoke-WebRequest) forbidden in Pester unit tests' },
|
|
85
|
+
@{ Pattern = '\bInvoke-RestMethod\b'; Reason = 'network access (Invoke-RestMethod) forbidden in Pester unit tests' },
|
|
86
|
+
@{ Pattern = '\[System\.Net\.Http\.'; Reason = 'System.Net.Http usage forbidden in Pester unit tests' },
|
|
87
|
+
@{ Pattern = '\[System\.Net\.WebRequest\]'; Reason = 'System.Net.WebRequest usage forbidden in Pester unit tests' },
|
|
88
|
+
@{ Pattern = '\[System\.Net\.Sockets\.'; Reason = 'raw socket access forbidden in Pester unit tests' },
|
|
89
|
+
@{ Pattern = '\bStart-Process\b'; Reason = 'Start-Process forbidden in Pester unit tests; mock the wrapper seam instead' },
|
|
90
|
+
@{ Pattern = '\bStart-Sleep\b'; Reason = 'Start-Sleep forbidden in Pester unit tests; avoid timing hacks' }
|
|
91
|
+
)
|
|
92
|
+
|
|
93
|
+
$violations = @()
|
|
94
|
+
foreach ($entry in $forbiddenPatterns) {
|
|
95
|
+
if ($content -match $entry.Pattern) {
|
|
96
|
+
$violations += $entry.Reason
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
if ($violations.Count -eq 0) {
|
|
101
|
+
exit 0
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
$uniqueViolations = $violations | Select-Object -Unique
|
|
105
|
+
$reason = "PowerShell unit test purity violations in '$filePath': " + ($uniqueViolations -join '; ') + ". Replace with wrapper-seam mocks, in-memory fakes, or pure code paths per .agents/skills/powershell/SKILL.md."
|
|
106
|
+
|
|
107
|
+
$response = @{
|
|
108
|
+
decision = 'block'
|
|
109
|
+
reason = $reason
|
|
110
|
+
} | ConvertTo-Json -Compress
|
|
111
|
+
|
|
112
|
+
Write-Output $response
|
|
113
|
+
exit 0
|