opencode-agent-orchestration-kit 1.0.27
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/.github/CODEOWNERS +1 -0
- package/.github/ISSUE_TEMPLATE/bug_report.yml +65 -0
- package/.github/ISSUE_TEMPLATE/config.yml +11 -0
- package/.github/ISSUE_TEMPLATE/documentation.yml +22 -0
- package/.github/ISSUE_TEMPLATE/feature_request.yml +43 -0
- package/.github/PULL_REQUEST_TEMPLATE.md +25 -0
- package/.github/workflows/check.yml +47 -0
- package/CODE_OF_CONDUCT.md +24 -0
- package/CONTRIBUTING.md +52 -0
- package/LICENSE +201 -0
- package/NOTICE.md +23 -0
- package/README.md +806 -0
- package/SECURITY.md +17 -0
- package/docker/open-design/.env.example +6 -0
- package/docker/open-design/Dockerfile +50 -0
- package/docker/open-design/docker-compose.yml +18 -0
- package/docker/open-design/opencode-od/agents/od-worker.md +22 -0
- package/docker/open-design/opencode-od/opencode.json +24 -0
- package/docs/agents.md +21 -0
- package/docs/commands.md +16 -0
- package/docs/configuration.md +30 -0
- package/docs/docker-open-design.md +42 -0
- package/docs/impeccable.md +18 -0
- package/docs/installation.md +176 -0
- package/docs/models.md +17 -0
- package/docs/open-design.md +25 -0
- package/docs/quickstart.md +74 -0
- package/docs/releases/v1.0.10.md +46 -0
- package/docs/releases/v1.0.14.md +39 -0
- package/docs/releases/v1.0.27.md +66 -0
- package/docs/security.md +8 -0
- package/docs/superpowers/plans/2026-07-20-safe-installation-lifecycle.md +779 -0
- package/docs/superpowers/plans/2026-07-20-version-identity-and-releases.md +590 -0
- package/docs/superpowers/specs/2026-07-20-safe-installation-lifecycle-design.md +1350 -0
- package/docs/superpowers/specs/2026-07-20-version-identity-and-releases-design.md +557 -0
- package/docs/superpowers.md +34 -0
- package/docs/synology.md +30 -0
- package/docs/troubleshooting.md +54 -0
- package/docs/workflows.md +44 -0
- package/doctor.sh +5 -0
- package/env.example +15 -0
- package/install.sh +5 -0
- package/opencode/AGENTS.md +104 -0
- package/opencode/agents/debugger.md +41 -0
- package/opencode/agents/designer.md +93 -0
- package/opencode/agents/developer.md +180 -0
- package/opencode/agents/evaluator.md +35 -0
- package/opencode/agents/evolver.md +31 -0
- package/opencode/agents/lead.md +251 -0
- package/opencode/agents/researcher.md +76 -0
- package/opencode/agents/review_api.md +34 -0
- package/opencode/agents/review_coordinator.md +111 -0
- package/opencode/agents/review_quality.md +35 -0
- package/opencode/agents/review_security.md +35 -0
- package/opencode/agents/review_tests.md +37 -0
- package/opencode/agents/reviewer.md +116 -0
- package/opencode/agents/scoper.md +75 -0
- package/opencode/agents/specifier.md +116 -0
- package/opencode/commands/code-simplify.md +36 -0
- package/opencode/commands/design.md +27 -0
- package/opencode/commands/evolve.md +165 -0
- package/opencode/commands/feature.md +67 -0
- package/opencode/commands/implement.md +11 -0
- package/opencode/commands/init.md +34 -0
- package/opencode/commands/loop.md +145 -0
- package/opencode/commands/mvp-spec.md +20 -0
- package/opencode/commands/plan.md +74 -0
- package/opencode/commands/research.md +12 -0
- package/opencode/commands/review-orchestrated.md +47 -0
- package/opencode/commands/review-preflight.md +26 -0
- package/opencode/commands/review.md +18 -0
- package/opencode/commands/scope.md +36 -0
- package/opencode/commands/spec.md +12 -0
- package/opencode/commands/test.md +40 -0
- package/opencode/docs/ai/evolution/README.md +135 -0
- package/opencode/docs/ai/evolution/benchmarks/manual-scenarios.md +123 -0
- package/opencode/docs/ai/evolution/benchmarks/router-scenarios.jsonl +8 -0
- package/opencode/docs/ai/evolution/evolution_history.md +83 -0
- package/opencode/docs/ai/evolution/mechanisms.jsonl +7 -0
- package/opencode/docs/ai/evolution/rejected_mechanisms.jsonl +2 -0
- package/opencode/docs/ai/evolution/runs/README.md +15 -0
- package/opencode/docs/ai/evolution/runs/iteration-001-sidecar/analysis/overview.md +12 -0
- package/opencode/docs/ai/evolution/runs/iteration-001-sidecar/change_evaluation.json +108 -0
- package/opencode/docs/ai/evolution/runs/iteration-001-sidecar/change_manifest.json +52 -0
- package/opencode/docs/ai/evolution/runs/iteration-001-sidecar/evaluation.md +19 -0
- package/opencode/docs/ai/evolution/runs/iteration-001-sidecar/post_evaluation.md +12 -0
- package/opencode/docs/ai/evolution/runs/iteration-002-feature-flow-fix/analysis/overview.md +7 -0
- package/opencode/docs/ai/evolution/runs/iteration-002-feature-flow-fix/change_evaluation.json +31 -0
- package/opencode/docs/ai/evolution/runs/iteration-002-feature-flow-fix/evaluation.md +19 -0
- package/opencode/docs/ai/evolution/runs/iteration-003-agent-readable-harness/analysis/overview.md +13 -0
- package/opencode/docs/ai/evolution/runs/iteration-003-agent-readable-harness/change_evaluation.json +66 -0
- package/opencode/docs/ai/evolution/runs/iteration-003-agent-readable-harness/change_manifest.json +82 -0
- package/opencode/docs/ai/evolution/runs/iteration-003-agent-readable-harness/evaluation.md +20 -0
- package/opencode/docs/ai/evolution/runs/iteration-004-orchestration-audit/analysis/detail/ahe-run-lifecycle-validator.md +40 -0
- package/opencode/docs/ai/evolution/runs/iteration-004-orchestration-audit/analysis/detail/evolve-evaluation-only-contract.md +15 -0
- package/opencode/docs/ai/evolution/runs/iteration-004-orchestration-audit/analysis/detail/open-design-tool-contract.md +14 -0
- package/opencode/docs/ai/evolution/runs/iteration-004-orchestration-audit/analysis/detail/slash-command-contract-coverage.md +40 -0
- package/opencode/docs/ai/evolution/runs/iteration-004-orchestration-audit/analysis/overview.md +17 -0
- package/opencode/docs/ai/evolution/runs/iteration-004-orchestration-audit/analysis/pre_apply_approval.md +15 -0
- package/opencode/docs/ai/evolution/runs/iteration-004-orchestration-audit/change_evaluation.json +252 -0
- package/opencode/docs/ai/evolution/runs/iteration-004-orchestration-audit/change_manifest.json +210 -0
- package/opencode/docs/ai/evolution/runs/iteration-004-orchestration-audit/evaluation.md +25 -0
- package/opencode/docs/ai/evolution/runs/iteration-004-orchestration-audit/post_apply_evaluation.md +15 -0
- package/opencode/docs/ai/evolution/runs/iteration-004-orchestration-audit/post_manifest_evaluation.md +14 -0
- package/opencode/docs/ai/evolution/runs/iteration-004-orchestration-audit/pre_apply_evaluation.md +15 -0
- package/opencode/docs/ai/evolution/runs/iteration-005-harness-orchestration-audit/analysis/overview.md +13 -0
- package/opencode/docs/ai/evolution/runs/iteration-005-harness-orchestration-audit/change_evaluation.json +14 -0
- package/opencode/docs/ai/evolution/runs/iteration-005-harness-orchestration-audit/change_manifest.json +30 -0
- package/opencode/docs/ai/evolution/runs/iteration-005-harness-orchestration-audit/evaluation.md +25 -0
- package/opencode/docs/ai/evolution/runs/iteration-006-lead-delegation-audit/analysis/overview.md +13 -0
- package/opencode/docs/ai/evolution/runs/iteration-006-lead-delegation-audit/change_evaluation.json +14 -0
- package/opencode/docs/ai/evolution/runs/iteration-006-lead-delegation-audit/change_manifest.json +29 -0
- package/opencode/docs/ai/evolution/runs/iteration-006-lead-delegation-audit/evaluation.md +18 -0
- package/opencode/docs/ai/evolution/runs/iteration-007-agent-skills-integration/analysis/overview.md +13 -0
- package/opencode/docs/ai/evolution/runs/iteration-007-agent-skills-integration/change_evaluation.json +14 -0
- package/opencode/docs/ai/evolution/runs/iteration-007-agent-skills-integration/change_manifest.json +34 -0
- package/opencode/docs/ai/evolution/runs/iteration-007-agent-skills-integration/evaluation.md +17 -0
- package/opencode/docs/ai/evolution/runs/iteration-008-lead-readonly-shell-permissions/analysis/overview.md +13 -0
- package/opencode/docs/ai/evolution/runs/iteration-008-lead-readonly-shell-permissions/change_evaluation.json +12 -0
- package/opencode/docs/ai/evolution/runs/iteration-008-lead-readonly-shell-permissions/change_manifest.json +28 -0
- package/opencode/docs/ai/evolution/runs/iteration-008-lead-readonly-shell-permissions/evaluation.md +17 -0
- package/opencode/docs/ai/evolution/runs/iteration-009-lead-developer-ownership-loop/analysis/overview.md +9 -0
- package/opencode/docs/ai/evolution/runs/iteration-009-lead-developer-ownership-loop/change_evaluation.json +14 -0
- package/opencode/docs/ai/evolution/runs/iteration-009-lead-developer-ownership-loop/change_manifest.json +31 -0
- package/opencode/docs/ai/evolution/runs/iteration-009-lead-developer-ownership-loop/evaluation.md +18 -0
- package/opencode/docs/ai/evolution/runs/iteration-010-token-plugin-sidebar-content/analysis/overview.md +12 -0
- package/opencode/docs/ai/evolution/runs/iteration-010-token-plugin-sidebar-content/change_evaluation.json +14 -0
- package/opencode/docs/ai/evolution/runs/iteration-010-token-plugin-sidebar-content/change_manifest.json +31 -0
- package/opencode/docs/ai/evolution/runs/iteration-010-token-plugin-sidebar-content/evaluation.md +17 -0
- package/opencode/docs/ai/evolution/runs/iteration-011-lead-cd-which-permissions/analysis/overview.md +10 -0
- package/opencode/docs/ai/evolution/runs/iteration-011-lead-cd-which-permissions/change_evaluation.json +14 -0
- package/opencode/docs/ai/evolution/runs/iteration-011-lead-cd-which-permissions/change_manifest.json +30 -0
- package/opencode/docs/ai/evolution/runs/iteration-011-lead-cd-which-permissions/evaluation.md +17 -0
- package/opencode/docs/ai/evolution/runs/iteration-012-lead-shell-allowlist-boundaries/analysis/overview.md +25 -0
- package/opencode/docs/ai/evolution/runs/iteration-012-lead-shell-allowlist-boundaries/change_evaluation.json +28 -0
- package/opencode/docs/ai/evolution/runs/iteration-012-lead-shell-allowlist-boundaries/change_manifest.json +31 -0
- package/opencode/docs/ai/evolution/runs/iteration-012-lead-shell-allowlist-boundaries/evaluation.md +22 -0
- package/opencode/docs/ai/evolution/runs/iteration-013-doc-gardening-mechanical-checks/analysis/overview.md +27 -0
- package/opencode/docs/ai/evolution/runs/iteration-013-doc-gardening-mechanical-checks/change_evaluation.json +32 -0
- package/opencode/docs/ai/evolution/runs/iteration-013-doc-gardening-mechanical-checks/change_manifest.json +49 -0
- package/opencode/docs/ai/evolution/runs/iteration-013-doc-gardening-mechanical-checks/evaluation.md +92 -0
- package/opencode/docs/ai/evolution/runs/iteration-014-harness-baseline/analysis/detail/token-vs-semantic.md +31 -0
- package/opencode/docs/ai/evolution/runs/iteration-014-harness-baseline/analysis/overview.md +14 -0
- package/opencode/docs/ai/evolution/runs/iteration-014-harness-baseline/evaluation.md +36 -0
- package/opencode/docs/ai/evolution/runs/iteration-015-semantic-checker/analysis/overview.md +13 -0
- package/opencode/docs/ai/evolution/runs/iteration-015-semantic-checker/change_evaluation.json +31 -0
- package/opencode/docs/ai/evolution/runs/iteration-015-semantic-checker/change_manifest.json +47 -0
- package/opencode/docs/ai/evolution/runs/iteration-015-semantic-checker/evaluation.md +27 -0
- package/opencode/docs/ai/evolution/runs/iteration-016-contract-prompt-alignment/analysis/overview.md +32 -0
- package/opencode/docs/ai/evolution/runs/iteration-016-contract-prompt-alignment/change_evaluation.json +31 -0
- package/opencode/docs/ai/evolution/runs/iteration-016-contract-prompt-alignment/change_manifest.json +35 -0
- package/opencode/docs/ai/evolution/runs/iteration-016-contract-prompt-alignment/evaluation.md +31 -0
- package/opencode/docs/ai/evolution/runs/iteration-017-ahe-cycle/analysis/detail/pattern-1-feature-sidecar-false-positive.md +51 -0
- package/opencode/docs/ai/evolution/runs/iteration-017-ahe-cycle/analysis/detail/pattern-2-checker-time-budget.md +52 -0
- package/opencode/docs/ai/evolution/runs/iteration-017-ahe-cycle/analysis/overview.md +99 -0
- package/opencode/docs/ai/evolution/runs/iteration-017-ahe-cycle/change_evaluation.json +61 -0
- package/opencode/docs/ai/evolution/runs/iteration-017-ahe-cycle/change_manifest.json +61 -0
- package/opencode/docs/ai/evolution/runs/iteration-017-ahe-cycle/evaluation.md +448 -0
- package/opencode/docs/ai/evolution/runs/iteration-018-free-message-routing-audit/analysis/detail/intake-gray-zone.md +65 -0
- package/opencode/docs/ai/evolution/runs/iteration-018-free-message-routing-audit/analysis/overview.md +172 -0
- package/opencode/docs/ai/evolution/runs/iteration-018-free-message-routing-audit/evaluation.md +226 -0
- package/opencode/docs/ai/evolution/runs/iteration-019-handoff-routing-audit/analysis/detail/plan-only-gray-zone.md +62 -0
- package/opencode/docs/ai/evolution/runs/iteration-019-handoff-routing-audit/analysis/overview.md +167 -0
- package/opencode/docs/ai/evolution/runs/iteration-019-handoff-routing-audit/evaluation.md +163 -0
- package/opencode/docs/ai/evolution/runs/iteration-020-loop-engineering-command/analysis/overview.md +42 -0
- package/opencode/docs/ai/evolution/runs/iteration-020-loop-engineering-command/change_evaluation.json +46 -0
- package/opencode/docs/ai/evolution/runs/iteration-020-loop-engineering-command/change_manifest.json +57 -0
- package/opencode/docs/ai/evolution/runs/iteration-020-loop-engineering-command/evaluation.md +48 -0
- package/opencode/docs/ai/evolution/runs/iteration-021/analysis/detail/contract-vs-runtime-gap.md +163 -0
- package/opencode/docs/ai/evolution/runs/iteration-021/analysis/detail/evidence-collection-blocker.md +134 -0
- package/opencode/docs/ai/evolution/runs/iteration-021/analysis/overview.md +111 -0
- package/opencode/docs/ai/evolution/runs/iteration-021/change_evaluation.json +52 -0
- package/opencode/docs/ai/evolution/runs/iteration-021/change_manifest.json +50 -0
- package/opencode/docs/ai/evolution/runs/iteration-021/evaluation.md +46 -0
- package/opencode/docs/ai/evolution/runs/iteration-021/manifest-justification.md +48 -0
- package/opencode/docs/ai/evolution/session-sources.md +91 -0
- package/opencode/docs/ai/harness/README.md +32 -0
- package/opencode/docs/ai/harness/agents.md +148 -0
- package/opencode/docs/ai/harness/checks.md +119 -0
- package/opencode/docs/ai/harness/commands.md +391 -0
- package/opencode/docs/ai/harness/evidence.md +85 -0
- package/opencode/docs/ai/harness/init-detection-rules.md +160 -0
- package/opencode/docs/ai/harness/orchestrated-review.md +131 -0
- package/opencode/docs/ai/harness/skill-metadata-schema.md +198 -0
- package/opencode/docs/ai/harness/skill-resolution.md +202 -0
- package/opencode/docs/ai/harness/skill_registry.json +443 -0
- package/opencode/docs/ai/harness/skill_registry.md +43 -0
- package/opencode/docs/ai/project-context-template.md +53 -0
- package/opencode/opencode.json +38 -0
- package/opencode/package-lock.json +1717 -0
- package/opencode/package.json +11 -0
- package/opencode/plugins/token-tree-usage.tsx +206 -0
- package/opencode/references/performance-checklist.md +153 -0
- package/opencode/references/security-checklist.md +134 -0
- package/opencode/references/testing-patterns.md +236 -0
- package/opencode/scripts/check-harness.mjs +1572 -0
- package/opencode/scripts/check-harness.test.mjs +820 -0
- package/opencode/scripts/collect-session-evidence.mjs +612 -0
- package/opencode/scripts/collect-session-evidence.test.mjs +443 -0
- package/opencode/scripts/preflight-audit.mjs +497 -0
- package/opencode/scripts/preflight-audit.test.mjs +363 -0
- package/opencode/scripts/project-capability-snapshot.mjs +407 -0
- package/opencode/scripts/project-capability-snapshot.test.mjs +382 -0
- package/opencode/scripts/review-orchestrated-prepare.mjs +547 -0
- package/opencode/scripts/review-orchestrated-prepare.test.mjs +516 -0
- package/opencode/scripts/skill-resolver.mjs +585 -0
- package/opencode/scripts/skill-resolver.test.mjs +781 -0
- package/opencode/scripts/update-skill-registry.mjs +380 -0
- package/opencode/skills/api-and-interface-design/SKILL.md +315 -0
- package/opencode/skills/autonomous-loops/SKILL.md +312 -0
- package/opencode/skills/code-review-and-quality/SKILL.md +365 -0
- package/opencode/skills/code-simplification/SKILL.md +345 -0
- package/opencode/skills/context-engineering/SKILL.md +252 -0
- package/opencode/skills/debugging-and-error-recovery/SKILL.md +316 -0
- package/opencode/skills/documentation-and-adrs/SKILL.md +298 -0
- package/opencode/skills/doubt-driven-development/SKILL.md +168 -0
- package/opencode/skills/iterative-retrieval/SKILL.md +232 -0
- package/opencode/skills/open-design/SKILL.md +123 -0
- package/opencode/skills/performance-optimization/SKILL.md +365 -0
- package/opencode/skills/security-and-hardening/SKILL.md +369 -0
- package/opencode/skills/source-driven-development/SKILL.md +210 -0
- package/opencode/skills/test-driven-development/SKILL.md +406 -0
- package/opencode/skills/using-agent-skills/SKILL.md +194 -0
- package/opencode/skills/verification-loop/SKILL.md +162 -0
- package/opencode/tools/open_design.ts +361 -0
- package/opencode/tui.json +5 -0
- package/package.json +20 -0
- package/rollback.sh +5 -0
- package/scripts/check.sh +184 -0
- package/scripts/install-smoke.sh +111 -0
- package/scripts/manage-installation.mjs +1498 -0
- package/scripts/manage-installation.test.mjs +1936 -0
- package/scripts/version.mjs +197 -0
- package/scripts/version.test.mjs +195 -0
- package/uninstall.sh +5 -0
- package/upgrade.sh +5 -0
package/scripts/check.sh
ADDED
|
@@ -0,0 +1,184 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
set -euo pipefail
|
|
3
|
+
|
|
4
|
+
root="$(CDPATH= cd -- "$(dirname -- "$0")/.." && pwd)"
|
|
5
|
+
cd "$root"
|
|
6
|
+
|
|
7
|
+
kit_version="$(node -p "require('./package.json').version")"
|
|
8
|
+
|
|
9
|
+
required_files="
|
|
10
|
+
README.md
|
|
11
|
+
LICENSE
|
|
12
|
+
NOTICE.md
|
|
13
|
+
SECURITY.md
|
|
14
|
+
.gitignore
|
|
15
|
+
env.example
|
|
16
|
+
install.sh
|
|
17
|
+
uninstall.sh
|
|
18
|
+
upgrade.sh
|
|
19
|
+
doctor.sh
|
|
20
|
+
rollback.sh
|
|
21
|
+
package.json
|
|
22
|
+
scripts/version.mjs
|
|
23
|
+
scripts/version.test.mjs
|
|
24
|
+
scripts/manage-installation.mjs
|
|
25
|
+
scripts/manage-installation.test.mjs
|
|
26
|
+
docs/releases/v${kit_version}.md
|
|
27
|
+
opencode/AGENTS.md
|
|
28
|
+
opencode/opencode.json
|
|
29
|
+
opencode/tui.json
|
|
30
|
+
opencode/.gitignore
|
|
31
|
+
opencode/package.json
|
|
32
|
+
opencode/package-lock.json
|
|
33
|
+
opencode/plugins/token-tree-usage.tsx
|
|
34
|
+
opencode/tools/open_design.ts
|
|
35
|
+
opencode/scripts/check-harness.mjs
|
|
36
|
+
opencode/commands/loop.md
|
|
37
|
+
opencode/commands/plan.md
|
|
38
|
+
opencode/commands/test.md
|
|
39
|
+
opencode/commands/code-simplify.md
|
|
40
|
+
opencode/docs/ai/harness/README.md
|
|
41
|
+
opencode/docs/ai/harness/agents.md
|
|
42
|
+
opencode/docs/ai/harness/commands.md
|
|
43
|
+
opencode/docs/ai/harness/evidence.md
|
|
44
|
+
opencode/docs/ai/harness/checks.md
|
|
45
|
+
opencode/docs/ai/evolution/README.md
|
|
46
|
+
opencode/docs/ai/evolution/evolution_history.md
|
|
47
|
+
opencode/docs/ai/evolution/mechanisms.jsonl
|
|
48
|
+
opencode/docs/ai/evolution/rejected_mechanisms.jsonl
|
|
49
|
+
opencode/docs/ai/evolution/benchmarks/manual-scenarios.md
|
|
50
|
+
opencode/docs/ai/evolution/benchmarks/router-scenarios.jsonl
|
|
51
|
+
docker/open-design/Dockerfile
|
|
52
|
+
docker/open-design/docker-compose.yml
|
|
53
|
+
docker/open-design/.env.example
|
|
54
|
+
docker/open-design/opencode-od/opencode.json
|
|
55
|
+
CODE_OF_CONDUCT.md
|
|
56
|
+
CONTRIBUTING.md
|
|
57
|
+
.github/PULL_REQUEST_TEMPLATE.md
|
|
58
|
+
.github/CODEOWNERS
|
|
59
|
+
.github/workflows/check.yml
|
|
60
|
+
.github/ISSUE_TEMPLATE/config.yml
|
|
61
|
+
.github/ISSUE_TEMPLATE/bug_report.yml
|
|
62
|
+
.github/ISSUE_TEMPLATE/feature_request.yml
|
|
63
|
+
.github/ISSUE_TEMPLATE/documentation.yml
|
|
64
|
+
"
|
|
65
|
+
|
|
66
|
+
for file in $required_files; do
|
|
67
|
+
test -f "$file" || { echo "Missing required file: $file" >&2; exit 1; }
|
|
68
|
+
done
|
|
69
|
+
|
|
70
|
+
for file in install.sh uninstall.sh upgrade.sh doctor.sh rollback.sh scripts/check.sh; do
|
|
71
|
+
test -x "$file" || { echo "Not executable: $file" >&2; exit 1; }
|
|
72
|
+
done
|
|
73
|
+
|
|
74
|
+
node scripts/version.mjs --check
|
|
75
|
+
|
|
76
|
+
node -e "JSON.parse(require('fs').readFileSync('opencode/opencode.json','utf8')); JSON.parse(require('fs').readFileSync('docker/open-design/opencode-od/opencode.json','utf8')); console.log('json ok')"
|
|
77
|
+
(cd opencode && node scripts/check-harness.mjs)
|
|
78
|
+
|
|
79
|
+
node <<'NODE'
|
|
80
|
+
const fs = require('fs')
|
|
81
|
+
const path = require('path')
|
|
82
|
+
for (const dir of ['opencode/agents', 'opencode/commands', ...fs.readdirSync('opencode/skills').map((name) => path.join('opencode/skills', name))]) {
|
|
83
|
+
for (const file of fs.readdirSync(dir).filter((name) => name.endsWith('.md'))) {
|
|
84
|
+
const full = path.join(dir, file)
|
|
85
|
+
const text = fs.readFileSync(full, 'utf8')
|
|
86
|
+
if (!text.startsWith('---\n')) throw new Error(`${full} missing frontmatter start`)
|
|
87
|
+
if (text.indexOf('\n---\n', 4) === -1) throw new Error(`${full} missing frontmatter end`)
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
console.log('frontmatter ok')
|
|
91
|
+
NODE
|
|
92
|
+
|
|
93
|
+
grep -q 'superpowers@git+https://github.com/obra/superpowers.git' opencode/opencode.json
|
|
94
|
+
grep -q '"default_agent": "lead"' opencode/opencode.json
|
|
95
|
+
grep -q './plugins/token-tree-usage.tsx' opencode/tui.json
|
|
96
|
+
|
|
97
|
+
grep -q 'Open Design' README.md
|
|
98
|
+
grep -q 'Superpowers' README.md
|
|
99
|
+
grep -q 'Impeccable' README.md
|
|
100
|
+
|
|
101
|
+
grep -q '"open-design": allow' opencode/agents/designer.md
|
|
102
|
+
grep -q '"impeccable": allow' opencode/agents/designer.md
|
|
103
|
+
grep -q '"superpowers"' opencode/agents/designer.md && { echo 'designer should not allow superpowers' >&2; exit 1; } || true
|
|
104
|
+
grep -q 'mode: all' opencode/agents/developer.md
|
|
105
|
+
grep -q 'Direct mode without slash commands' opencode/agents/developer.md
|
|
106
|
+
grep -q 'Default behavior without slash commands' opencode/agents/lead.md
|
|
107
|
+
grep -q 'fast router' opencode/agents/lead.md
|
|
108
|
+
grep -q 'Ask the user' opencode/agents/lead.md
|
|
109
|
+
grep -q 'edit: deny' opencode/agents/lead.md
|
|
110
|
+
grep -Fq '"cd *": allow' opencode/agents/lead.md
|
|
111
|
+
grep -Fq '"which *": allow' opencode/agents/lead.md
|
|
112
|
+
|
|
113
|
+
grep -q 'researcher: allow' opencode/agents/scoper.md
|
|
114
|
+
grep -q 'specifier: allow' opencode/agents/scoper.md
|
|
115
|
+
! grep -q 'developer: allow' opencode/agents/scoper.md
|
|
116
|
+
! grep -q 'designer: allow' opencode/agents/scoper.md
|
|
117
|
+
|
|
118
|
+
grep -q 'Never invoke `developer` before' opencode/agents/lead.md
|
|
119
|
+
grep -q 'Never invoke `reviewer` before' opencode/agents/lead.md
|
|
120
|
+
grep -q 'agent: lead' opencode/commands/feature.md
|
|
121
|
+
grep -q 'agent: lead' opencode/commands/plan.md
|
|
122
|
+
grep -q 'approval_gate: explicit_before_writes' opencode/commands/loop.md
|
|
123
|
+
grep -q 'max_iterations_per_invocation: 3' opencode/commands/loop.md
|
|
124
|
+
grep -q 'completion_authority: reviewer_only' opencode/commands/loop.md
|
|
125
|
+
grep -q 'agent: scoper' opencode/commands/scope.md
|
|
126
|
+
grep -q 'agent: designer' opencode/commands/design.md
|
|
127
|
+
grep -q 'agent: developer' opencode/commands/test.md
|
|
128
|
+
grep -q 'agent: developer' opencode/commands/code-simplify.md
|
|
129
|
+
grep -q 'evaluator' opencode/commands/evolve.md
|
|
130
|
+
grep -q 'debugger' opencode/commands/evolve.md
|
|
131
|
+
grep -q 'evolver' opencode/commands/evolve.md
|
|
132
|
+
|
|
133
|
+
grep -q 'OPEN_DESIGN_URL' opencode/tools/open_design.ts
|
|
134
|
+
grep -q 'baseUrl: tool.schema.string().optional()' opencode/tools/open_design.ts
|
|
135
|
+
! grep -q 'randomUUID' opencode/tools/open_design.ts
|
|
136
|
+
! grep -q 'from "node:crypto"' opencode/tools/open_design.ts
|
|
137
|
+
|
|
138
|
+
node <<'NODE'
|
|
139
|
+
const fs = require('fs')
|
|
140
|
+
const rootPackage = JSON.parse(fs.readFileSync('package.json', 'utf8'))
|
|
141
|
+
if (rootPackage.dependencies?.['@opencode-ai/plugin']) {
|
|
142
|
+
throw new Error('package.json should not carry @opencode-ai/plugin; keep it scoped to opencode/package.json')
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
const opencodePackage = JSON.parse(fs.readFileSync('opencode/package.json', 'utf8'))
|
|
146
|
+
if (opencodePackage.dependencies?.['@opencode-ai/plugin'] !== '1.14.41') {
|
|
147
|
+
throw new Error('opencode/package.json must pin @opencode-ai/plugin to 1.14.41')
|
|
148
|
+
}
|
|
149
|
+
if (opencodePackage.dependencies?.['@opentui/core'] !== '0.2.5') {
|
|
150
|
+
throw new Error('opencode/package.json must pin @opentui/core to 0.2.5')
|
|
151
|
+
}
|
|
152
|
+
if (opencodePackage.dependencies?.['@opentui/solid'] !== '0.2.5') {
|
|
153
|
+
throw new Error('opencode/package.json must pin @opentui/solid to 0.2.5')
|
|
154
|
+
}
|
|
155
|
+
if (opencodePackage.dependencies?.['solid-js'] !== '1.9.12') {
|
|
156
|
+
throw new Error('opencode/package.json must pin solid-js to 1.9.12')
|
|
157
|
+
}
|
|
158
|
+
if (opencodePackage.overrides?.uuid !== '^14.0.0') {
|
|
159
|
+
throw new Error('opencode/package.json must override uuid to ^14.0.0')
|
|
160
|
+
}
|
|
161
|
+
NODE
|
|
162
|
+
|
|
163
|
+
grep -q 'Lead' opencode/plugins/token-tree-usage.tsx
|
|
164
|
+
grep -q 'Subagents' opencode/plugins/token-tree-usage.tsx
|
|
165
|
+
grep -q 'Partial total' opencode/plugins/token-tree-usage.tsx
|
|
166
|
+
|
|
167
|
+
private_re="$(printf '%s|%s|%s|%s' '/''Users/' 'synology''\\.me' 'auth''\\.json' 'OPENAI''_API_KEY')"
|
|
168
|
+
if grep -R -nE "$private_re" . \
|
|
169
|
+
--exclude-dir=.git \
|
|
170
|
+
--exclude-dir=node_modules \
|
|
171
|
+
--exclude='.git' \
|
|
172
|
+
--exclude='check.sh' \
|
|
173
|
+
--exclude='.gitignore'; then
|
|
174
|
+
echo 'Potential private data found' >&2
|
|
175
|
+
exit 1
|
|
176
|
+
fi
|
|
177
|
+
|
|
178
|
+
grep -q 'Apache License' LICENSE
|
|
179
|
+
grep -q 'OpenCode' NOTICE.md
|
|
180
|
+
grep -q 'Open Design' NOTICE.md
|
|
181
|
+
grep -q 'Impeccable' NOTICE.md
|
|
182
|
+
grep -q 'Superpowers' NOTICE.md
|
|
183
|
+
|
|
184
|
+
echo 'check ok'
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
set -euo pipefail
|
|
3
|
+
|
|
4
|
+
root="$(CDPATH= cd -- "$(dirname -- "$0")/.." && pwd)"
|
|
5
|
+
smoke_parent="${TMPDIR:-/tmp}"
|
|
6
|
+
smoke_parent="${smoke_parent%/}"
|
|
7
|
+
smoke_root="$(mktemp -d "$smoke_parent/oak-install-smoke.XXXXXX")"
|
|
8
|
+
target="$smoke_root/opencode"
|
|
9
|
+
|
|
10
|
+
cleanup() {
|
|
11
|
+
case "$smoke_root" in
|
|
12
|
+
"$smoke_parent"/oak-install-smoke.*) rm -rf -- "$smoke_root" ;;
|
|
13
|
+
*) echo "Refusing unsafe smoke cleanup: $smoke_root" >&2; return 1 ;;
|
|
14
|
+
esac
|
|
15
|
+
}
|
|
16
|
+
trap cleanup EXIT
|
|
17
|
+
|
|
18
|
+
cd "$root"
|
|
19
|
+
expected_version="$(node -p "require('./package.json').version")"
|
|
20
|
+
expected_line="opencode-agent-orchestration-kit $expected_version"
|
|
21
|
+
|
|
22
|
+
for wrapper in install.sh upgrade.sh doctor.sh uninstall.sh rollback.sh; do
|
|
23
|
+
test "$("./$wrapper" --version)" = "$expected_line"
|
|
24
|
+
done
|
|
25
|
+
|
|
26
|
+
node --input-type=module - "$root/opencode" "$target" <<'NODE'
|
|
27
|
+
import { createInstallationManager } from "./scripts/manage-installation.mjs"
|
|
28
|
+
const [, , sourceRoot, targetRoot] = process.argv
|
|
29
|
+
const result = await createInstallationManager({
|
|
30
|
+
sourceRoot,
|
|
31
|
+
versionProvider: () => "1.0.26",
|
|
32
|
+
}).run("install", { targetRoot })
|
|
33
|
+
if (result.exitCode !== 0) throw result.error ?? new Error("smoke install failed")
|
|
34
|
+
NODE
|
|
35
|
+
|
|
36
|
+
test -f "$target/AGENTS.md"
|
|
37
|
+
test -f "$target/opencode.json"
|
|
38
|
+
test -f "$target/scripts/check-harness.mjs"
|
|
39
|
+
test -f "$target/.oak/manifest.json"
|
|
40
|
+
test -f "$target/.oak/rollback/transaction.json"
|
|
41
|
+
|
|
42
|
+
node --input-type=module - "$target" <<'NODE'
|
|
43
|
+
import fs from "node:fs"
|
|
44
|
+
import path from "node:path"
|
|
45
|
+
const target = process.argv[2]
|
|
46
|
+
const manifest = JSON.parse(fs.readFileSync(path.join(target, ".oak", "manifest.json"), "utf8"))
|
|
47
|
+
const rollback = JSON.parse(fs.readFileSync(path.join(target, ".oak", "rollback", "transaction.json"), "utf8"))
|
|
48
|
+
if (manifest.kit_version !== "1.0.26") throw new Error("initial manifest version mismatch")
|
|
49
|
+
if (rollback.previous_manifest !== null || rollback.next_manifest?.kit_version !== "1.0.26") {
|
|
50
|
+
throw new Error("initial rollback snapshot version mismatch")
|
|
51
|
+
}
|
|
52
|
+
NODE
|
|
53
|
+
|
|
54
|
+
manifest_before="$(shasum -a 256 "$target/.oak/manifest.json" | awk '{print $1}')"
|
|
55
|
+
./upgrade.sh --dry-run --target "$target" >/dev/null
|
|
56
|
+
manifest_after="$(shasum -a 256 "$target/.oak/manifest.json" | awk '{print $1}')"
|
|
57
|
+
test "$manifest_before" = "$manifest_after"
|
|
58
|
+
|
|
59
|
+
./upgrade.sh --target "$target" >/dev/null
|
|
60
|
+
node --input-type=module - "$target" "$expected_version" <<'NODE'
|
|
61
|
+
import fs from "node:fs"
|
|
62
|
+
import path from "node:path"
|
|
63
|
+
const [, , target, expected] = process.argv
|
|
64
|
+
const manifest = JSON.parse(fs.readFileSync(path.join(target, ".oak", "manifest.json"), "utf8"))
|
|
65
|
+
const rollback = JSON.parse(fs.readFileSync(path.join(target, ".oak", "rollback", "transaction.json"), "utf8"))
|
|
66
|
+
if (manifest.kit_version !== expected) throw new Error("upgraded manifest version mismatch")
|
|
67
|
+
if (rollback.previous_manifest?.kit_version !== "1.0.26" || rollback.next_manifest?.kit_version !== expected) {
|
|
68
|
+
throw new Error("upgrade snapshot version mismatch")
|
|
69
|
+
}
|
|
70
|
+
NODE
|
|
71
|
+
|
|
72
|
+
./uninstall.sh --yes --target "$target" >/dev/null
|
|
73
|
+
test ! -e "$target/AGENTS.md"
|
|
74
|
+
test ! -e "$target/.oak/manifest.json"
|
|
75
|
+
test -f "$target/.oak/rollback/transaction.json"
|
|
76
|
+
|
|
77
|
+
node --input-type=module - "$target" "$expected_version" <<'NODE'
|
|
78
|
+
import fs from "node:fs"
|
|
79
|
+
import path from "node:path"
|
|
80
|
+
const [, , target, expected] = process.argv
|
|
81
|
+
const rollback = JSON.parse(fs.readFileSync(path.join(target, ".oak", "rollback", "transaction.json"), "utf8"))
|
|
82
|
+
if (rollback.previous_manifest?.kit_version !== expected || rollback.next_manifest !== null) {
|
|
83
|
+
throw new Error("uninstall snapshot version mismatch")
|
|
84
|
+
}
|
|
85
|
+
NODE
|
|
86
|
+
|
|
87
|
+
./rollback.sh --target "$target" >/dev/null
|
|
88
|
+
test -f "$target/AGENTS.md"
|
|
89
|
+
test -f "$target/.oak/manifest.json"
|
|
90
|
+
node --input-type=module - "$target" "$expected_version" <<'NODE'
|
|
91
|
+
import fs from "node:fs"
|
|
92
|
+
import path from "node:path"
|
|
93
|
+
const [, , target, expected] = process.argv
|
|
94
|
+
const manifest = JSON.parse(fs.readFileSync(path.join(target, ".oak", "manifest.json"), "utf8"))
|
|
95
|
+
if (manifest.kit_version !== expected) throw new Error("rollback-restored manifest version mismatch")
|
|
96
|
+
NODE
|
|
97
|
+
./doctor.sh --target "$target" | grep -q 'doctor: current'
|
|
98
|
+
|
|
99
|
+
if find "$smoke_root" -maxdepth 1 -name "$(basename "$target").backup.*" -print -quit | grep -q .; then
|
|
100
|
+
echo "Unexpected sibling backup directory" >&2
|
|
101
|
+
exit 1
|
|
102
|
+
fi
|
|
103
|
+
|
|
104
|
+
(
|
|
105
|
+
cd "$target"
|
|
106
|
+
npm ci
|
|
107
|
+
node scripts/check-harness.mjs
|
|
108
|
+
node --input-type=module -e "import('@opencode-ai/plugin').then(() => console.log('installed plugin import ok'))"
|
|
109
|
+
)
|
|
110
|
+
|
|
111
|
+
echo "installation smoke ok"
|