@pi-harness/pi-harness 0.1.28 → 0.1.30
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/README.md +1 -1
- package/apps/web/dist/assets/{index-1vaEg8Vr.js → index-B7pwZ76Z.js} +2 -2
- package/apps/web/dist/index.html +1 -1
- package/apps/web/package.json +1 -15
- package/apps/web/profile/cordis.yml +73 -73
- package/apps/web/server-dist/bin.js +4 -2
- package/apps/web/server-dist/bin.js.map +1 -1
- package/apps/web/src/server/bin.ts +4 -2
- package/apps/web/test/bin.test.ts +6 -0
- package/node_modules/@pi-harness/api-gateway/dist/index.d.ts.map +1 -1
- package/node_modules/@pi-harness/api-gateway/dist/index.js +5 -12
- package/node_modules/@pi-harness/api-gateway/dist/index.js.map +1 -1
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/agent-teams.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/anchored-standard.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/annotation.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/archify.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/at-file.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/auto-mode.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/better-sidebar.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/browser-fetch.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/browser-session.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/canvas-draw.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/change-verifier.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/cleaner.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/cli-notifier.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/code2skill.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/colleague-skill.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/context-doctor.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/context.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/cost-meter.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/dependency-checker.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/docker-sandbox.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/fail-logger.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/genui.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/git-time-capsule.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/graph-memory.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/history-compressor.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/hol-guard.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/i18n-pair.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/image-compressor.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/llm-verifier.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/mcp-client.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/mcp-panel.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/memory.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/mirage-bridge.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/mock-server.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/modlens.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/module-search.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/obsidian-sync.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/openpets.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/plan-execute.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/plugin-check.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/plugin-dev.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/plugin-finder.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/plugin-radar.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/plugin-stars.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/prompt-guard.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/prompt-library.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/readme-gen.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/recall-unread.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/reverse-skill.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/reviewer-bot.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/runtime-doctor.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/secure-audit.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/session-bookmarks.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/session-bridge.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/session-compare.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/session-export.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/session-insights.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/session-search.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/skill-catalog.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/skill-guard.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/sql-lens.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/synapse.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/tab-manager.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/taskboard.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/telemetry-blocker.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/test-harness.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/theme-studio.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/token-guard.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/turn-rewind.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/undo-savepoint.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/vision-toolkit.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/web-research.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/workspace-navigator.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/workspace-search.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace-entries/official/yaml-validator.json +3 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace.d.ts +0 -1
- package/node_modules/@pi-harness/api-gateway/dist/marketplace.d.ts.map +1 -1
- package/node_modules/@pi-harness/api-gateway/dist/marketplace.js +0 -3
- package/node_modules/@pi-harness/api-gateway/dist/marketplace.js.map +1 -1
- package/node_modules/@pi-harness/api-gateway/package.json +27 -1
- package/node_modules/@pi-harness/cli/dist/bin.js +2 -1
- package/node_modules/@pi-harness/cli/dist/bin.js.map +1 -1
- package/node_modules/@pi-harness/cli/dist/main.d.ts +2 -0
- package/node_modules/@pi-harness/cli/dist/main.d.ts.map +1 -1
- package/node_modules/@pi-harness/cli/dist/main.js +12 -2
- package/node_modules/@pi-harness/cli/dist/main.js.map +1 -1
- package/node_modules/@pi-harness/cli/dist/profiles.d.ts +3 -0
- package/node_modules/@pi-harness/cli/dist/profiles.d.ts.map +1 -0
- package/node_modules/@pi-harness/cli/dist/profiles.js +5 -0
- package/node_modules/@pi-harness/cli/dist/profiles.js.map +1 -0
- package/node_modules/@pi-harness/cli/package.json +3 -2
- package/node_modules/@pi-harness/cli/profiles/default/cordis.yml +122 -0
- package/node_modules/@pi-harness/cli/profiles/development/cordis.yml +47 -0
- package/node_modules/@pi-harness/host-webserver/package.json +1 -1
- package/node_modules/@pi-harness/web-app/package.json +1 -1
- package/package.json +88 -15
- package/packages/api-gateway/dist/index.d.ts.map +1 -1
- package/packages/api-gateway/dist/index.js +5 -12
- package/packages/api-gateway/dist/index.js.map +1 -1
- package/packages/api-gateway/dist/marketplace-entries/official/agent-teams.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/anchored-standard.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/annotation.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/archify.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/at-file.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/auto-mode.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/better-sidebar.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/browser-fetch.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/browser-session.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/canvas-draw.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/change-verifier.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/cleaner.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/cli-notifier.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/code2skill.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/colleague-skill.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/context-doctor.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/context.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/cost-meter.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/dependency-checker.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/docker-sandbox.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/fail-logger.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/genui.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/git-time-capsule.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/graph-memory.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/history-compressor.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/hol-guard.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/i18n-pair.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/image-compressor.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/llm-verifier.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/mcp-client.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/mcp-panel.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/memory.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/mirage-bridge.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/mock-server.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/modlens.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/module-search.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/obsidian-sync.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/openpets.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/plan-execute.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/plugin-check.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/plugin-dev.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/plugin-finder.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/plugin-radar.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/plugin-stars.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/prompt-guard.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/prompt-library.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/readme-gen.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/recall-unread.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/reverse-skill.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/reviewer-bot.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/runtime-doctor.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/secure-audit.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/session-bookmarks.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/session-bridge.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/session-compare.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/session-export.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/session-insights.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/session-search.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/skill-catalog.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/skill-guard.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/sql-lens.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/synapse.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/tab-manager.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/taskboard.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/telemetry-blocker.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/test-harness.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/theme-studio.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/token-guard.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/turn-rewind.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/undo-savepoint.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/vision-toolkit.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/web-research.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/workspace-navigator.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/workspace-search.json +3 -3
- package/packages/api-gateway/dist/marketplace-entries/official/yaml-validator.json +3 -3
- package/packages/api-gateway/dist/marketplace.d.ts +0 -1
- package/packages/api-gateway/dist/marketplace.d.ts.map +1 -1
- package/packages/api-gateway/dist/marketplace.js +0 -3
- package/packages/api-gateway/dist/marketplace.js.map +1 -1
- package/packages/api-gateway/package.json +27 -1
- package/packages/api-gateway/src/index.ts +4 -12
- package/packages/api-gateway/src/marketplace-entries/official/agent-teams.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/anchored-standard.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/annotation.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/archify.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/at-file.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/auto-mode.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/better-sidebar.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/browser-fetch.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/browser-session.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/canvas-draw.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/change-verifier.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/cleaner.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/cli-notifier.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/code2skill.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/colleague-skill.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/context-doctor.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/context.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/cost-meter.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/dependency-checker.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/docker-sandbox.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/fail-logger.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/genui.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/git-time-capsule.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/graph-memory.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/history-compressor.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/hol-guard.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/i18n-pair.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/image-compressor.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/llm-verifier.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/mcp-client.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/mcp-panel.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/memory.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/mirage-bridge.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/mock-server.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/modlens.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/module-search.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/obsidian-sync.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/openpets.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/plan-execute.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/plugin-check.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/plugin-dev.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/plugin-finder.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/plugin-radar.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/plugin-stars.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/prompt-guard.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/prompt-library.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/readme-gen.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/recall-unread.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/reverse-skill.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/reviewer-bot.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/runtime-doctor.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/secure-audit.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/session-bookmarks.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/session-bridge.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/session-compare.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/session-export.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/session-insights.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/session-search.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/skill-catalog.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/skill-guard.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/sql-lens.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/synapse.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/tab-manager.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/taskboard.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/telemetry-blocker.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/test-harness.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/theme-studio.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/token-guard.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/turn-rewind.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/undo-savepoint.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/vision-toolkit.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/web-research.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/workspace-navigator.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/workspace-search.json +3 -3
- package/packages/api-gateway/src/marketplace-entries/official/yaml-validator.json +3 -3
- package/packages/api-gateway/src/marketplace.ts +0 -4
- package/packages/api-gateway/test/index.test.ts +140 -94
- package/packages/api-gateway/test/marketplace-schema.test.ts +1 -1
- package/packages/api-gateway/test/marketplace.test.ts +7 -9
- package/packages/api-gateway/test/packed-package.test.ts +95 -11
- package/packages/api-gateway/test/release-contract.test.ts +37 -6
- package/packages/api-gateway/test/release-package.test.ts +1 -1
- package/packages/api-gateway/test/release-version.test.ts +79 -3
- package/packages/bundle-web-app/package.json +1 -1
- package/packages/cli/dist/bin.js +2 -1
- package/packages/cli/dist/bin.js.map +1 -1
- package/packages/cli/dist/main.d.ts +2 -0
- package/packages/cli/dist/main.d.ts.map +1 -1
- package/packages/cli/dist/main.js +12 -2
- package/packages/cli/dist/main.js.map +1 -1
- package/packages/cli/dist/profiles.d.ts +3 -0
- package/packages/cli/dist/profiles.d.ts.map +1 -0
- package/packages/cli/dist/profiles.js +5 -0
- package/packages/cli/dist/profiles.js.map +1 -0
- package/packages/cli/package.json +3 -2
- package/packages/cli/profiles/default/cordis.yml +122 -0
- package/packages/cli/profiles/development/cordis.yml +47 -0
- package/packages/cli/src/bin.ts +2 -1
- package/packages/cli/src/main.ts +14 -2
- package/packages/cli/src/profiles.ts +6 -0
- package/packages/cli/test/binary.test.ts +5 -1
- package/packages/cli/test/broken-pipe.test.ts +1 -1
- package/packages/cli/test/cli.test.ts +1 -0
- package/packages/cli/test/main.test.ts +1 -0
- package/packages/cli/test/profiles.integration.test.ts +575 -0
- package/packages/host-webserver/package.json +1 -1
|
@@ -130,7 +130,7 @@ describe("marketplace entry schema", () => {
|
|
|
130
130
|
expect(validate(schema, { ...validEntry(), category: { id: "Not Kebab", label: "x" } })).not.toEqual([]);
|
|
131
131
|
expect(validate(schema, { ...validEntry(), category: { id: "collaboration", label: " " } })).not.toEqual([]);
|
|
132
132
|
expect(validate(schema, { ...validEntry(), packageName: "Not/Valid Name" })).not.toEqual([]);
|
|
133
|
-
expect(validate(schema, { ...validEntry(), profile: { name: "@pi-harness/
|
|
133
|
+
expect(validate(schema, { ...validEntry(), profile: { name: "@pi-harness/plugin-agent-teams", config: [] } })).not.toEqual([]);
|
|
134
134
|
expect(validate(schema, { ...groupEntry(), profile: { name: "@deepseek-ai/cordis-plugin-group", group: true, config: {} } })).not.toEqual([]);
|
|
135
135
|
expect(validate(schema, { ...validEntry(), capabilities: [] })).not.toEqual([]);
|
|
136
136
|
expect(validate(schema, { ...validEntry(), repository: "http://example.com" })).not.toEqual([]);
|
|
@@ -6,7 +6,6 @@ import {
|
|
|
6
6
|
attachMarketplaceStatistics,
|
|
7
7
|
createMarketplaceStatisticsLoader,
|
|
8
8
|
marketplaceNpmPackageName,
|
|
9
|
-
needsMarketplacePackageInstall,
|
|
10
9
|
paginateMarketplace,
|
|
11
10
|
searchMarketplace,
|
|
12
11
|
sortMarketplaceByRecommendation,
|
|
@@ -474,13 +473,11 @@ describe("plugin marketplace registry", () => {
|
|
|
474
473
|
expect(official.get("better-sidebar")?.category.id).toBe("developer");
|
|
475
474
|
});
|
|
476
475
|
|
|
477
|
-
test("
|
|
478
|
-
const
|
|
479
|
-
|
|
480
|
-
expect(
|
|
481
|
-
expect(
|
|
482
|
-
expect(needsMarketplacePackageInstall(bundled!)).toBe(false);
|
|
483
|
-
expect(needsMarketplacePackageInstall(external!)).toBe(true);
|
|
476
|
+
test("lists every plugin as an installable npm package rather than a launcher subpath", () => {
|
|
477
|
+
const subpaths = MARKETPLACE_PLUGINS.filter((plugin) => plugin.packageName.includes("/plugins/"));
|
|
478
|
+
expect(subpaths).toEqual([]);
|
|
479
|
+
expect(MARKETPLACE_PLUGINS.every((plugin) => marketplaceNpmPackageName(plugin.packageName) === plugin.packageName)).toBe(true);
|
|
480
|
+
expect(MARKETPLACE_PLUGINS.find((plugin) => plugin.id === "skill-guard")?.packageName).toBe("@pi-harness/plugin-skill-guard");
|
|
484
481
|
});
|
|
485
482
|
|
|
486
483
|
test("filters by query and capability without mutating the registry", () => {
|
|
@@ -510,7 +507,8 @@ describe("plugin marketplace registry", () => {
|
|
|
510
507
|
});
|
|
511
508
|
|
|
512
509
|
test("maps plugin entry points to their published npm package", () => {
|
|
513
|
-
expect(marketplaceNpmPackageName("@pi-harness/
|
|
510
|
+
expect(marketplaceNpmPackageName("@pi-harness/plugin-agent-teams")).toBe("@pi-harness/plugin-agent-teams");
|
|
511
|
+
expect(marketplaceNpmPackageName("@example-scope/toolkit/plugins/subpath")).toBe("@example-scope/toolkit");
|
|
514
512
|
expect(marketplaceNpmPackageName("@deepseek-ai/cordis-plugin-timer")).toBe("@deepseek-ai/cordis-plugin-timer");
|
|
515
513
|
expect(marketplaceNpmPackageName("unscoped-package/runtime")).toBe("unscoped-package");
|
|
516
514
|
});
|
|
@@ -9,29 +9,76 @@ const execFileAsync = promisify(execFile);
|
|
|
9
9
|
const fixtures: string[] = [];
|
|
10
10
|
const repositoryRoot = resolve(import.meta.dirname, "../../..");
|
|
11
11
|
|
|
12
|
-
// Stands in for
|
|
13
|
-
|
|
14
|
-
|
|
12
|
+
// Stands in for the launcher's own @pi-harness/core inside the installed tree, so the smoke test can drive the marketplace stage without a real global install. Both modules are reduced to the behaviour that stage depends on.
|
|
13
|
+
const fakeCoreSource = `import { mkdirSync, readFileSync, writeFileSync } from "node:fs";
|
|
14
|
+
import { join } from "node:path";
|
|
15
|
+
|
|
16
|
+
export const prepareHarnessProfile = ({ builtinProfilePath, profileName, directory }) => {
|
|
17
|
+
const profileDirectory = join(directory, "profiles", profileName);
|
|
18
|
+
mkdirSync(profileDirectory, { recursive: true });
|
|
19
|
+
writeFileSync(join(directory, "package.json"), JSON.stringify({ name: "pi-harness-home", private: true }));
|
|
20
|
+
const profilePath = join(profileDirectory, "cordis.yml");
|
|
21
|
+
writeFileSync(profilePath, readFileSync(builtinProfilePath, "utf8"));
|
|
22
|
+
return Promise.resolve(profilePath);
|
|
23
|
+
};
|
|
24
|
+
`;
|
|
25
|
+
|
|
26
|
+
const fakeResolveSource = `import { existsSync } from "node:fs";
|
|
15
27
|
import { dirname, join } from "node:path";
|
|
28
|
+
|
|
29
|
+
export const resolvePluginEntry = (fromFile, name) => {
|
|
30
|
+
let directory = dirname(fromFile);
|
|
31
|
+
for (;;) {
|
|
32
|
+
const candidate = join(directory, "node_modules", ...name.split("/"), "dist", "index.js");
|
|
33
|
+
if (existsSync(candidate)) return candidate;
|
|
34
|
+
const parent = dirname(directory);
|
|
35
|
+
if (parent === directory) return undefined;
|
|
36
|
+
directory = parent;
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
`;
|
|
40
|
+
|
|
41
|
+
// Stands in for npm so the smoke test can be exercised without packing and globally installing the real workspace: `pack` reports one tarball name per requested workspace, a `--prefix` install lays out the tree the script inspects, optionally without the files the root bin map points at, and a plain install lays out the marketplace package in the directory it was run from.
|
|
42
|
+
const fakeNpmSource = `import { mkdirSync, writeFileSync } from "node:fs";
|
|
43
|
+
import { basename, dirname, join } from "node:path";
|
|
16
44
|
import process from "node:process";
|
|
17
45
|
|
|
18
46
|
const args = process.argv.slice(2);
|
|
19
47
|
if (args[0] === "pack") {
|
|
20
|
-
|
|
48
|
+
const workspaces = args.filter((argument, index) => args[index - 1] === "--workspace");
|
|
49
|
+
// The root is packed with its scripts, so prepack's own build output shares this stdout with the tarball name.
|
|
50
|
+
const lines = workspaces.length === 0 ? ["> pi-harness build:web", "built 75 plugin packages in 3 waves", "harness.tgz"] : workspaces.map((name) => name.slice(name.indexOf("/") + 1) + ".tgz");
|
|
51
|
+
process.stdout.write(lines.join("\\n") + "\\n");
|
|
21
52
|
process.exit(0);
|
|
22
53
|
}
|
|
23
54
|
if (args[0] !== "install") process.exit(1);
|
|
24
|
-
const prefix = args[args.indexOf("--prefix") + 1];
|
|
25
|
-
const harnessRoot = join(prefix, "lib", "node_modules", "@pi-harness", "pi-harness");
|
|
26
|
-
const agentRoot = join(harnessRoot, "node_modules", "@earendil-works", "pi-coding-agent");
|
|
27
55
|
const write = (path, content) => {
|
|
28
56
|
mkdirSync(dirname(path), { recursive: true });
|
|
29
57
|
writeFileSync(path, content);
|
|
30
58
|
};
|
|
59
|
+
const prefixIndex = args.indexOf("--prefix");
|
|
60
|
+
if (prefixIndex < 0) {
|
|
61
|
+
if (process.env.PACKED_PACKAGE_FIXTURE_MARKETPLACE !== "0") {
|
|
62
|
+
const name = "@pi-harness/" + basename(args[args.length - 1]).replace(/\\.tgz$/u, "");
|
|
63
|
+
const root = join(process.cwd(), "node_modules", ...name.split("/"));
|
|
64
|
+
write(join(root, "package.json"), JSON.stringify({ name, version: "9.9.9", type: "module", exports: { ".": { import: "./dist/index.js" } } }));
|
|
65
|
+
write(join(root, "dist", "index.js"), "export default {};\\n");
|
|
66
|
+
}
|
|
67
|
+
process.exit(0);
|
|
68
|
+
}
|
|
69
|
+
const prefix = args[prefixIndex + 1];
|
|
70
|
+
const harnessRoot = join(prefix, "lib", "node_modules", "@pi-harness", "pi-harness");
|
|
71
|
+
const agentRoot = join(harnessRoot, "node_modules", "@earendil-works", "pi-coding-agent");
|
|
31
72
|
const bin = { "pi-harness": "./apps/web/server-dist/bin.js", pih: "./packages/cli/dist/bin.js" };
|
|
32
73
|
write(join(harnessRoot, "package.json"), JSON.stringify({ name: "@pi-harness/pi-harness", version: "9.9.9", bin, dependencies: { "@earendil-works/pi-coding-agent": "0.84.4" } }));
|
|
33
74
|
write(join(agentRoot, "package.json"), JSON.stringify({ name: "@earendil-works/pi-coding-agent", version: "0.84.4", dependencies: {} }));
|
|
34
75
|
write(join(agentRoot, "dist", "cli", "args.js"), "");
|
|
76
|
+
write(join(harnessRoot, "apps", "web", "profile", "cordis.yml"), "- id: modlens\\n name: \\"@pi-harness/plugin-modlens\\"\\n");
|
|
77
|
+
const shippedDependencies = process.env.PACKED_PACKAGE_FIXTURE_SHIPPED_DEP === "1" ? { "@pi-harness/client-web": "9.9.9" } : undefined;
|
|
78
|
+
write(join(harnessRoot, "apps", "web", "package.json"), JSON.stringify({ name: "@pi-harness/web", private: true, dependencies: shippedDependencies }));
|
|
79
|
+
if (process.env.PACKED_PACKAGE_FIXTURE_PROFILE_PLUGIN !== "0") write(join(harnessRoot, "node_modules", "@pi-harness", "plugin-modlens", "dist", "index.js"), "export default {};\\n");
|
|
80
|
+
write(join(harnessRoot, "node_modules", "@pi-harness", "core", "dist", "index.js"), process.env.PACKED_PACKAGE_FIXTURE_CORE);
|
|
81
|
+
write(join(harnessRoot, "node_modules", "@pi-harness", "core", "dist", "plugin-resolve.js"), process.env.PACKED_PACKAGE_FIXTURE_RESOLVE);
|
|
35
82
|
if (process.env.PACKED_PACKAGE_FIXTURE_BINS === "1") for (const target of Object.values(bin)) write(join(harnessRoot, target), "");
|
|
36
83
|
`;
|
|
37
84
|
|
|
@@ -43,9 +90,24 @@ const createFakeNpm = async (): Promise<string> => {
|
|
|
43
90
|
return fakeNpm;
|
|
44
91
|
};
|
|
45
92
|
|
|
46
|
-
const runSmokeTest = async (
|
|
93
|
+
const runSmokeTest = async (
|
|
94
|
+
fakeNpm: string,
|
|
95
|
+
bins: boolean,
|
|
96
|
+
marketplace = true,
|
|
97
|
+
profilePlugin = true,
|
|
98
|
+
shippedDependency = false,
|
|
99
|
+
): ReturnType<typeof execFileAsync> =>
|
|
47
100
|
execFileAsync(process.execPath, [resolve(repositoryRoot, "scripts/test-packed-package.mjs")], {
|
|
48
|
-
env: {
|
|
101
|
+
env: {
|
|
102
|
+
...process.env,
|
|
103
|
+
npm_execpath: fakeNpm,
|
|
104
|
+
PACKED_PACKAGE_FIXTURE_BINS: bins ? "1" : "0",
|
|
105
|
+
PACKED_PACKAGE_FIXTURE_CORE: fakeCoreSource,
|
|
106
|
+
PACKED_PACKAGE_FIXTURE_RESOLVE: fakeResolveSource,
|
|
107
|
+
PACKED_PACKAGE_FIXTURE_MARKETPLACE: marketplace ? "1" : "0",
|
|
108
|
+
PACKED_PACKAGE_FIXTURE_PROFILE_PLUGIN: profilePlugin ? "1" : "0",
|
|
109
|
+
PACKED_PACKAGE_FIXTURE_SHIPPED_DEP: shippedDependency ? "1" : "0",
|
|
110
|
+
},
|
|
49
111
|
});
|
|
50
112
|
|
|
51
113
|
afterEach(async () => {
|
|
@@ -53,7 +115,7 @@ afterEach(async () => {
|
|
|
53
115
|
});
|
|
54
116
|
|
|
55
117
|
describe("packed package smoke test", () => {
|
|
56
|
-
it("accepts a tarball whose bin entrypoints are present", async () => {
|
|
118
|
+
it("accepts a tarball whose bin entrypoints are present and whose marketplace install is loadable", async () => {
|
|
57
119
|
const fakeNpm = await createFakeNpm();
|
|
58
120
|
|
|
59
121
|
const { stdout } = await runSmokeTest(fakeNpm, true);
|
|
@@ -62,9 +124,31 @@ describe("packed package smoke test", () => {
|
|
|
62
124
|
});
|
|
63
125
|
|
|
64
126
|
it("rejects a tarball that ships no runnable bin entrypoint", async () => {
|
|
65
|
-
// `
|
|
127
|
+
// A `files` allowlist that omits build output, or a prepack that failed to produce it, ships a bin map pointing at files the tarball does not contain.
|
|
66
128
|
const fakeNpm = await createFakeNpm();
|
|
67
129
|
|
|
68
130
|
await expect(runSmokeTest(fakeNpm, false)).rejects.toThrow(/missing the pi-harness entrypoint \.\/apps\/web\/server-dist\/bin\.js/u);
|
|
69
131
|
});
|
|
132
|
+
|
|
133
|
+
it("rejects an install whose shipped profile enables a plugin the tarball never brings in", async () => {
|
|
134
|
+
// The 0.1.29 launcher shipped a profile naming 45 packages it did not depend on, so a clean install failed to boot on the first entry the loader could not import.
|
|
135
|
+
const fakeNpm = await createFakeNpm();
|
|
136
|
+
|
|
137
|
+
await expect(runSmokeTest(fakeNpm, true, true, false)).rejects.toThrow(/enables 1 plugin\(s\) the install does not contain: @pi-harness\/plugin-modlens/u);
|
|
138
|
+
});
|
|
139
|
+
|
|
140
|
+
it("rejects an install whose shipped workspace depends on a package npm can never fetch", async () => {
|
|
141
|
+
// apps/web is built out of two private workspaces, so the dependency list 0.1.29 shipped made every npm command run inside the installation fail with E404 on @pi-harness/client-web.
|
|
142
|
+
const fakeNpm = await createFakeNpm();
|
|
143
|
+
|
|
144
|
+
await expect(runSmokeTest(fakeNpm, true, true, true, true)).rejects.toThrow(
|
|
145
|
+
/apps\/web\/package\.json depends on @pi-harness\/client-web, which the install neither contains nor can fetch/u,
|
|
146
|
+
);
|
|
147
|
+
});
|
|
148
|
+
|
|
149
|
+
it("rejects a launcher whose marketplace install lands somewhere the loader cannot resolve", async () => {
|
|
150
|
+
const fakeNpm = await createFakeNpm();
|
|
151
|
+
|
|
152
|
+
await expect(runSmokeTest(fakeNpm, true, false)).rejects.toThrow(/installed into the harness home but the loader cannot resolve it/u);
|
|
153
|
+
});
|
|
70
154
|
});
|
|
@@ -43,6 +43,25 @@ describe("release contract", () => {
|
|
|
43
43
|
expect(workflow).toContain("npm publish --access public");
|
|
44
44
|
});
|
|
45
45
|
|
|
46
|
+
test("publishes every plugin package on its own version line", () => {
|
|
47
|
+
// A plugin carries its own semver, so the release has to know which plugins actually changed instead of bumping all of them behind the launcher.
|
|
48
|
+
expect(workflow).toContain('node scripts/set-release-version.mjs "$version" --base "$previous_tag"');
|
|
49
|
+
expect(workflow).toContain("git describe --tags --abbrev=0 --match 'v*' HEAD");
|
|
50
|
+
// The publish loop walks the plugins in dependency order, and the release commit has to carry their bumped manifests.
|
|
51
|
+
expect(workflow).toContain("$(node scripts/build-plugins.mjs --order)");
|
|
52
|
+
expect(workflow).toContain("packages/plugins/*/package.json");
|
|
53
|
+
const pluginManifests = readdirSync(resolve(repositoryRoot, "packages/plugins"), { withFileTypes: true })
|
|
54
|
+
.filter((entry) => entry.isDirectory())
|
|
55
|
+
.map((entry) => entry.name);
|
|
56
|
+
expect(pluginManifests.length).toBeGreaterThan(0);
|
|
57
|
+
for (const directory of pluginManifests) {
|
|
58
|
+
const manifest = readJson(`packages/plugins/${directory}/package.json`) as { name: string; dependencies?: Record<string, string> };
|
|
59
|
+
// An exact pin would rewrite - and therefore republish - every plugin on each launcher patch release, which is the coupling the split removed.
|
|
60
|
+
for (const [dependency, range] of Object.entries(manifest.dependencies ?? {}))
|
|
61
|
+
if (dependency.startsWith("@pi-harness/")) expect(range, `${manifest.name} pins ${dependency} instead of tracking it through a range`).toMatch(/^\^/u);
|
|
62
|
+
}
|
|
63
|
+
});
|
|
64
|
+
|
|
46
65
|
test("pins every action to a full commit SHA with its release tag recorded", () => {
|
|
47
66
|
const uses = [...workflow.matchAll(/^\s+uses:\s*(.+)$/gmu)].map((match) => match[1] ?? "");
|
|
48
67
|
expect(uses.length).toBeGreaterThanOrEqual(2);
|
|
@@ -51,13 +70,14 @@ describe("release contract", () => {
|
|
|
51
70
|
|
|
52
71
|
test("prepack builds every workspace that a root bin points at", () => {
|
|
53
72
|
const root = readJson("package.json") as { bin: Record<string, string>; scripts: Record<string, string> };
|
|
54
|
-
|
|
73
|
+
// The rest of prepack prepares the manifests the tarball ships, which package-install.test.ts owns; this test only cares that the build still runs before anything is packed.
|
|
74
|
+
expect(root.scripts.prepack).toContain("npm run build:web");
|
|
55
75
|
const built = [...root.scripts["build:web"]!.matchAll(/npm run build -w (\S+)/gu)].map((match) => match[1]);
|
|
56
76
|
for (const target of Object.values(root.bin)) expect(built, `${target} is not built by build:web`).toContain(workspaceNameFor(target));
|
|
57
77
|
expect(built.indexOf("@pi-harness/core")).toBeLessThan(built.indexOf("@pi-harness/cli"));
|
|
58
78
|
});
|
|
59
79
|
|
|
60
|
-
test("core declares every package its sources
|
|
80
|
+
test("core declares every package its sources load", () => {
|
|
61
81
|
const core = readJson("packages/core/package.json") as { name: string; dependencies: Record<string, string>; peerDependencies: Record<string, string> };
|
|
62
82
|
const specifierPattern =
|
|
63
83
|
/(?:from\s*|import\s*\(\s*|import\.meta\.resolve\(\s*|require(?:\.resolve)?\(\s*)["']([@a-z][^"'\s]*)["']|"(@[a-z0-9._~-]+\/[a-z0-9._~-]+(?:\/[a-z0-9._~-]+)*)"/gu;
|
|
@@ -66,10 +86,6 @@ describe("release contract", () => {
|
|
|
66
86
|
for (const match of readFileSync(file, "utf8").matchAll(specifierPattern))
|
|
67
87
|
required.set(packageNameOf(match[1] ?? match[2] ?? ""), relative(repositoryRoot, file));
|
|
68
88
|
}
|
|
69
|
-
for (const file of sourceFiles(resolve(repositoryRoot, "packages/core/profiles"), ".yml")) {
|
|
70
|
-
for (const match of readFileSync(file, "utf8").matchAll(/^\s*name:\s*"?([^"\s]+)"?\s*$/gmu))
|
|
71
|
-
required.set(packageNameOf(match[1] ?? ""), relative(repositoryRoot, file));
|
|
72
|
-
}
|
|
73
89
|
const external = [...required].filter(([name]) => !name.startsWith("node:") && !name.includes(":") && name !== core.name);
|
|
74
90
|
expect(external.length).toBeGreaterThan(0);
|
|
75
91
|
// A runtime that appears in the published type surface is declared as a peer instead, so the consumer owns the single installed copy.
|
|
@@ -78,6 +94,21 @@ describe("release contract", () => {
|
|
|
78
94
|
core.dependencies[name] ?? core.peerDependencies[name],
|
|
79
95
|
`${name} (used by ${file}) is declared by neither ${core.name} dependencies nor peerDependencies`,
|
|
80
96
|
).toBeDefined();
|
|
97
|
+
// The curated plugin set belongs to the launcher, so installing the runtime on its own never drags a profile's plugins in.
|
|
98
|
+
expect(core.files).not.toContain("profiles");
|
|
99
|
+
});
|
|
100
|
+
|
|
101
|
+
test("the published launcher declares every plugin package its shipped profiles load", () => {
|
|
102
|
+
// Every plugin in a shipped profile is now an ordinary npm package, so the package a user installs has to pull each one like any other dependency.
|
|
103
|
+
const root = readJson("package.json") as { name: string; dependencies: Record<string, string> };
|
|
104
|
+
const required = new Map<string, string>();
|
|
105
|
+
for (const file of sourceFiles(resolve(repositoryRoot, "packages/cli/profiles"), ".yml")) {
|
|
106
|
+
for (const match of readFileSync(file, "utf8").matchAll(/^\s*name:\s*"?([^"\s]+)"?\s*$/gmu))
|
|
107
|
+
required.set(packageNameOf(match[1] ?? ""), relative(repositoryRoot, file));
|
|
108
|
+
}
|
|
109
|
+
const external = [...required].filter(([name]) => !name.includes(":"));
|
|
110
|
+
expect(external.filter(([name]) => name.startsWith("@pi-harness/plugin-")).length).toBeGreaterThan(0);
|
|
111
|
+
for (const [name, file] of external) expect(root.dependencies[name], `${name} (loaded by ${file}) is not declared by ${root.name}`).toBeDefined();
|
|
81
112
|
});
|
|
82
113
|
|
|
83
114
|
test("the plugin API declares every package its sources import as a peer", () => {
|
|
@@ -59,7 +59,7 @@ describe("release package", () => {
|
|
|
59
59
|
expect((core.dependencies as Record<string, string>)["@pi-harness/plugin-api"]).toBe(rootManifest.version);
|
|
60
60
|
|
|
61
61
|
const workflow = await readFile(resolve(repositoryRoot, ".github/workflows/release.yml"), "utf8");
|
|
62
|
-
expect(workflow).toContain("for workspace in packages/plugin-api packages/core .; do");
|
|
62
|
+
expect(workflow).toContain("for workspace in packages/plugin-api packages/core $(node scripts/build-plugins.mjs --order) .; do");
|
|
63
63
|
expect(workflow).toContain("for package_name in @pi-harness/plugin-api @pi-harness/core @pi-harness/pi-harness; do");
|
|
64
64
|
});
|
|
65
65
|
|
|
@@ -23,7 +23,7 @@ describe("release version preparation", () => {
|
|
|
23
23
|
it("synchronizes manifests, lock data, and internal marketplace entries without changing external versions", async () => {
|
|
24
24
|
const fixture = await mkdtemp(resolve(tmpdir(), "pi-harness-release-version-"));
|
|
25
25
|
fixtures.push(fixture);
|
|
26
|
-
await Promise.all([mkdir(resolve(fixture, "apps")), mkdir(resolve(fixture, "examples"))]);
|
|
26
|
+
await Promise.all([mkdir(resolve(fixture, "apps")), mkdir(resolve(fixture, "examples")), mkdir(resolve(fixture, "packages/plugins"), { recursive: true })]);
|
|
27
27
|
await writeJson(fixture, "package.json", { name: "@pi-harness/pi-harness", version: "0.1.2", dependencies: { "@pi-harness/core": "0.1.2" } });
|
|
28
28
|
await writeJson(fixture, "packages/core/package.json", { name: "@pi-harness/core", version: "0.1.2" });
|
|
29
29
|
await writeJson(fixture, "packages/api-gateway/package.json", { name: "@pi-harness/api-gateway", version: "0.1.2" });
|
|
@@ -83,7 +83,7 @@ describe("release version preparation", () => {
|
|
|
83
83
|
// A re-dispatched release run checks out the release commit, so every manifest and marketplace entry already holds the requested version.
|
|
84
84
|
const fixture = await mkdtemp(resolve(tmpdir(), "pi-harness-release-version-"));
|
|
85
85
|
fixtures.push(fixture);
|
|
86
|
-
await Promise.all([mkdir(resolve(fixture, "apps")), mkdir(resolve(fixture, "examples"))]);
|
|
86
|
+
await Promise.all([mkdir(resolve(fixture, "apps")), mkdir(resolve(fixture, "examples")), mkdir(resolve(fixture, "packages/plugins"), { recursive: true })]);
|
|
87
87
|
await writeJson(fixture, "package.json", { name: "@pi-harness/pi-harness", version: "0.1.3", dependencies: { "@pi-harness/core": "^0.1.3" } });
|
|
88
88
|
await writeJson(fixture, "packages/core/package.json", { name: "@pi-harness/core", version: "0.1.3" });
|
|
89
89
|
await writeJson(fixture, "packages/api-gateway/package.json", { name: "@pi-harness/api-gateway", version: "0.1.3" });
|
|
@@ -103,10 +103,86 @@ describe("release version preparation", () => {
|
|
|
103
103
|
expect(await readFile(resolve(fixture, "packages/api-gateway/dist/marketplace-entries/official/internal.json"), "utf8")).toBe(formattedInternalEntry);
|
|
104
104
|
});
|
|
105
105
|
|
|
106
|
+
it("moves a plugin package's version only when that plugin changed", async () => {
|
|
107
|
+
// A plugin is published on its own, so the release train's version means nothing to it: an untouched plugin keeps the version already on npm and is skipped by the publish step.
|
|
108
|
+
const fixture = await mkdtemp(resolve(tmpdir(), "pi-harness-release-version-"));
|
|
109
|
+
fixtures.push(fixture);
|
|
110
|
+
await Promise.all([mkdir(resolve(fixture, "apps")), mkdir(resolve(fixture, "examples")), mkdir(resolve(fixture, "packages/plugins"), { recursive: true })]);
|
|
111
|
+
await writeJson(fixture, "package.json", {
|
|
112
|
+
name: "@pi-harness/pi-harness",
|
|
113
|
+
version: "0.1.2",
|
|
114
|
+
dependencies: { "@pi-harness/core": "0.1.2", "@pi-harness/plugin-alpha": "0.2.5", "@pi-harness/plugin-beta": "0.1.2" },
|
|
115
|
+
});
|
|
116
|
+
await writeJson(fixture, "packages/core/package.json", { name: "@pi-harness/core", version: "0.1.2" });
|
|
117
|
+
await writeJson(fixture, "packages/plugin-api/package.json", { name: "@pi-harness/plugin-api", version: "0.1.2" });
|
|
118
|
+
await writeJson(fixture, "packages/api-gateway/package.json", { name: "@pi-harness/api-gateway", version: "0.1.2" });
|
|
119
|
+
await writeJson(fixture, "packages/plugins/alpha/package.json", {
|
|
120
|
+
name: "@pi-harness/plugin-alpha",
|
|
121
|
+
version: "0.2.5",
|
|
122
|
+
dependencies: { "@pi-harness/plugin-api": "^0.1.2" },
|
|
123
|
+
});
|
|
124
|
+
await writeJson(fixture, "packages/plugins/beta/package.json", {
|
|
125
|
+
name: "@pi-harness/plugin-beta",
|
|
126
|
+
version: "0.1.2",
|
|
127
|
+
dependencies: { "@pi-harness/plugin-api": "^0.1.2" },
|
|
128
|
+
});
|
|
129
|
+
await writeFile(resolve(fixture, "packages/plugins/alpha/index.js"), "export default 1;\n");
|
|
130
|
+
await writeFile(resolve(fixture, "packages/plugins/beta/index.js"), "export default 1;\n");
|
|
131
|
+
await writeJson(fixture, "package-lock.json", {
|
|
132
|
+
name: "@pi-harness/pi-harness",
|
|
133
|
+
version: "0.1.2",
|
|
134
|
+
lockfileVersion: 3,
|
|
135
|
+
packages: {
|
|
136
|
+
"": { name: "@pi-harness/pi-harness", version: "0.1.2", dependencies: { "@pi-harness/plugin-alpha": "0.2.5" } },
|
|
137
|
+
"packages/plugins/alpha": { name: "@pi-harness/plugin-alpha", version: "0.2.5", dependencies: { "@pi-harness/plugin-api": "^0.1.2" } },
|
|
138
|
+
"packages/plugins/beta": { name: "@pi-harness/plugin-beta", version: "0.1.2" },
|
|
139
|
+
},
|
|
140
|
+
});
|
|
141
|
+
await mkdir(resolve(fixture, "packages/api-gateway/src/marketplace-entries/official"), { recursive: true });
|
|
142
|
+
await writeFile(
|
|
143
|
+
resolve(fixture, "packages/api-gateway/src/marketplace-entries/official/alpha.json"),
|
|
144
|
+
`{\n "packageName": "@pi-harness/plugin-alpha",\n "version": "0.2.5"\n}\n`,
|
|
145
|
+
);
|
|
146
|
+
await writeFile(
|
|
147
|
+
resolve(fixture, "packages/api-gateway/src/marketplace-entries/official/beta.json"),
|
|
148
|
+
`{\n "packageName": "@pi-harness/plugin-beta",\n "version": "0.1.2"\n}\n`,
|
|
149
|
+
);
|
|
150
|
+
await execFileAsync("git", ["init", "-q", "-b", "main"], { cwd: fixture });
|
|
151
|
+
await execFileAsync("git", ["config", "user.email", "release@test.invalid"], { cwd: fixture });
|
|
152
|
+
await execFileAsync("git", ["config", "user.name", "Release Test"], { cwd: fixture });
|
|
153
|
+
await execFileAsync("git", ["add", "-A"], { cwd: fixture });
|
|
154
|
+
await execFileAsync("git", ["commit", "-qm", "release fixture"], { cwd: fixture });
|
|
155
|
+
await execFileAsync("git", ["tag", "v0.1.2"], { cwd: fixture });
|
|
156
|
+
await writeFile(resolve(fixture, "packages/plugins/alpha/index.js"), "export default 2;\n");
|
|
157
|
+
await writeJson(fixture, "packages/plugins/gamma/package.json", { name: "@pi-harness/plugin-gamma", version: "0.0.0" });
|
|
158
|
+
|
|
159
|
+
await execFileAsync(process.execPath, [resolve(repositoryRoot, "scripts/set-release-version.mjs"), "0.1.3", "--base", "v0.1.2"], { cwd: fixture });
|
|
160
|
+
|
|
161
|
+
const read = async (path: string): Promise<Record<string, unknown>> =>
|
|
162
|
+
JSON.parse(await readFile(resolve(fixture, path), "utf8")) as Record<string, unknown>;
|
|
163
|
+
expect(await read("packages/plugins/alpha/package.json")).toMatchObject({ version: "0.2.6", dependencies: { "@pi-harness/plugin-api": "^0.1.2" } });
|
|
164
|
+
expect(await read("packages/plugins/beta/package.json")).toMatchObject({ version: "0.1.2" });
|
|
165
|
+
// A plugin that did not exist at the previous release joins at the train's version instead of starting from whatever its manifest happened to declare.
|
|
166
|
+
expect(await read("packages/plugins/gamma/package.json")).toMatchObject({ version: "0.1.3" });
|
|
167
|
+
expect(await read("package.json")).toMatchObject({
|
|
168
|
+
version: "0.1.3",
|
|
169
|
+
dependencies: { "@pi-harness/core": "^0.1.3", "@pi-harness/plugin-alpha": "0.2.6", "@pi-harness/plugin-beta": "0.1.2" },
|
|
170
|
+
});
|
|
171
|
+
expect(await read("package-lock.json")).toMatchObject({
|
|
172
|
+
packages: {
|
|
173
|
+
"": { dependencies: { "@pi-harness/plugin-alpha": "0.2.6" } },
|
|
174
|
+
"packages/plugins/alpha": { version: "0.2.6" },
|
|
175
|
+
"packages/plugins/beta": { version: "0.1.2" },
|
|
176
|
+
},
|
|
177
|
+
});
|
|
178
|
+
expect(await read("packages/api-gateway/src/marketplace-entries/official/alpha.json")).toMatchObject({ version: "0.2.6" });
|
|
179
|
+
expect(await read("packages/api-gateway/src/marketplace-entries/official/beta.json")).toMatchObject({ version: "0.1.2" });
|
|
180
|
+
});
|
|
181
|
+
|
|
106
182
|
it("rejects an internal marketplace entry without a top-level version field", async () => {
|
|
107
183
|
const fixture = await mkdtemp(resolve(tmpdir(), "pi-harness-release-version-"));
|
|
108
184
|
fixtures.push(fixture);
|
|
109
|
-
await Promise.all([mkdir(resolve(fixture, "apps")), mkdir(resolve(fixture, "examples"))]);
|
|
185
|
+
await Promise.all([mkdir(resolve(fixture, "apps")), mkdir(resolve(fixture, "examples")), mkdir(resolve(fixture, "packages/plugins"), { recursive: true })]);
|
|
110
186
|
await writeJson(fixture, "package.json", { name: "@pi-harness/pi-harness", version: "0.1.2" });
|
|
111
187
|
await writeJson(fixture, "packages/core/package.json", { name: "@pi-harness/core", version: "0.1.2" });
|
|
112
188
|
await writeJson(fixture, "packages/api-gateway/package.json", { name: "@pi-harness/api-gateway", version: "0.1.2" });
|
package/packages/cli/dist/bin.js
CHANGED
|
@@ -3,7 +3,7 @@ import { readFileSync } from "node:fs";
|
|
|
3
3
|
import { homedir } from "node:os";
|
|
4
4
|
import { join, resolve } from "node:path";
|
|
5
5
|
import { fileURLToPath } from "node:url";
|
|
6
|
-
import { coreUpdateNotice } from "@pi-harness/core";
|
|
6
|
+
import { coreUpdateNotice, harnessHomeDirectory } from "@pi-harness/core";
|
|
7
7
|
import { runCli } from "./main.js";
|
|
8
8
|
import { shouldRelaunchForDevelopmentProfile, superviseDevelopmentProcess } from "./relaunch.js";
|
|
9
9
|
const packageJson = JSON.parse(readFileSync(new URL("../package.json", import.meta.url), "utf8"));
|
|
@@ -12,6 +12,7 @@ const agentDir = configuredAgentDir === undefined || configuredAgentDir.length =
|
|
|
12
12
|
const environment = {
|
|
13
13
|
cwd: process.cwd(),
|
|
14
14
|
agentDir,
|
|
15
|
+
harnessHome: harnessHomeDirectory(),
|
|
15
16
|
version: packageJson.version,
|
|
16
17
|
supervised: process.env.PI_HARNESS_SUPERVISED === "1",
|
|
17
18
|
stdin: process.stdin,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bin.js","sourceRoot":"","sources":["../src/bin.ts"],"names":[],"mappings":";AAEA,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAClC,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"bin.js","sourceRoot":"","sources":["../src/bin.ts"],"names":[],"mappings":";AAEA,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;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E,qBAAqB,EAAE,GAAG,EAAE,EAAE,CAC1E,CAAC;IACJ,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,kEAAkE,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;QACnJ,OAAO,CAAC,QAAQ,GAAG,CAAC,CAAC;IACvB,CAAC;AACH,CAAC;KAAM,CAAC;IACN,OAAO,CAAC,QAAQ,GAAG,MAAM,MAAM,CAAC,IAAI,EAAE,WAAW,CAAC,CAAC;AACrD,CAAC"}
|
|
@@ -2,6 +2,8 @@ import type { Readable, Writable } from "node:stream";
|
|
|
2
2
|
export interface CliEnvironment {
|
|
3
3
|
readonly cwd: string;
|
|
4
4
|
readonly agentDir: string;
|
|
5
|
+
/** Directory that owns the booted copy of a built-in profile and the node_modules the marketplace installs into. */
|
|
6
|
+
readonly harnessHome: string;
|
|
5
7
|
readonly version: string;
|
|
6
8
|
readonly stdin: Readable;
|
|
7
9
|
readonly stdout: Writable;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../src/main.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../src/main.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAOtD,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;IAC1B,oHAAoH;IACpH,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,KAAK,EAAE,QAAQ,CAAC;IACzB,QAAQ,CAAC,MAAM,EAAE,QAAQ,CAAC;IAC1B,QAAQ,CAAC,MAAM,EAAE,QAAQ,CAAC;IAC1B,QAAQ,CAAC,iBAAiB,EAAE,MAAM,CAAC;IACnC,QAAQ,CAAC,eAAe,CAAC,EAAE,MAAM,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;IAC7D,QAAQ,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC;IAC9B,SAAS,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IAC9B,QAAQ,CAAC,QAAQ,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,OAAO,KAAK,IAAI,GAAG,MAAM,IAAI,CAAC;CAClE;AAgCD,eAAO,MAAM,0BAA0B,KAAK,CAAC;AAM7C,wBAAsB,MAAM,CAAC,KAAK,EAAE,SAAS,MAAM,EAAE,EAAE,YAAY,EAAE,cAAc,GAAG,OAAO,CAAC,MAAM,CAAC,CA4LpG"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { readFile } from "node:fs/promises";
|
|
2
|
-
import {
|
|
2
|
+
import { bootHarness, prepareHarnessProfile, provideLaunchContext, provideStdioContext, resolveProfileConfig } from "@pi-harness/core";
|
|
3
3
|
import { CliUsageError, parseLauncherArgs } from "./args.js";
|
|
4
4
|
import { NodeStdio } from "./node-stdio.js";
|
|
5
|
+
import { BUILTIN_PROFILES, BUILTIN_PROFILES_DIR } from "./profiles.js";
|
|
5
6
|
import { PI_HARNESS_RESTART_EXIT_CODE } from "./relaunch.js";
|
|
6
7
|
async function settleWithin(promise, timeoutMs) {
|
|
7
8
|
let timer;
|
|
@@ -55,9 +56,18 @@ export async function runCli(_args, _environment) {
|
|
|
55
56
|
let configPath;
|
|
56
57
|
try {
|
|
57
58
|
configPath = await resolveProfileConfig({
|
|
58
|
-
...(invocation.configPath === undefined
|
|
59
|
+
...(invocation.configPath === undefined
|
|
60
|
+
? { profile: invocation.profile ?? "default", profilesDir: BUILTIN_PROFILES_DIR }
|
|
61
|
+
: { configPath: invocation.configPath }),
|
|
59
62
|
cwd: environment.cwd,
|
|
60
63
|
});
|
|
64
|
+
// A built-in profile is a template: the copy under the harness home is what boots, because that is the file the web console appends marketplace entries to and the directory those packages are installed beside. An explicit --config already names a file the user owns, so it is booted as given.
|
|
65
|
+
if (invocation.configPath === undefined)
|
|
66
|
+
configPath = await prepareHarnessProfile({
|
|
67
|
+
builtinProfilePath: configPath,
|
|
68
|
+
profileName: invocation.profile ?? "default",
|
|
69
|
+
directory: environment.harnessHome,
|
|
70
|
+
});
|
|
61
71
|
if (invocation.dumpConfig) {
|
|
62
72
|
environment.stdout.write(await readFile(configPath, "utf8"));
|
|
63
73
|
return 0;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"main.js","sourceRoot":"","sources":["../src/main.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAE5C,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"main.js","sourceRoot":"","sources":["../src/main.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAE5C,OAAO,EAAE,WAAW,EAAE,qBAAqB,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,oBAAoB,EAAsB,MAAM,kBAAkB,CAAC;AAC3J,OAAO,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAC;AAC7D,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAC;AACvE,OAAO,EAAE,4BAA4B,EAAE,MAAM,eAAe,CAAC;AAoB7D,KAAK,UAAU,YAAY,CAAI,OAAmB,EAAE,SAAiB;IACnE,IAAI,KAAiC,CAAC;IACtC,MAAM,OAAO,GAAG,IAAI,OAAO,CAAq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QACzG,UAAU,GAAG,CAAC,CAAC;QACf,OAAO,CAAC,CAAC;IACX,CAAC;YAAS,CAAC;QACT,aAAa,EAAE,CAAC;QAChB,KAAK,CAAC,KAAK,EAAE,CAAC;QACd,IAAI,OAAO,KAAK,SAAS,EAAE,CAAC;YAC1B,MAAM,QAAQ,GAAG,MAAM,YAAY,CACjC,OAAO,CAAC,OAAO,EAAE,CAAC,IAAI,CACpB,GAAG,EAAE,CAAC,SAAS,EACf,CAAC,KAAc,EAAE,EAAE;gBACjB,WAAW,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,KAAK,IAAI,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;YAC3G,CAAC,CACF,EACD,WAAW,CAAC,iBAAiB,CAC9B,CAAC;YACF,IAAI,CAAC,QAAQ,CAAC,OAAO;gBAAE,MAAM,SAAS,CAAC,UAAU,IAAI,CAAC,CAAC,CAAC;QAC1D,CAAC;IACH,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"profiles.d.ts","sourceRoot":"","sources":["../src/profiles.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,gBAAgB,qCAAsC,CAAC;AAGpE,eAAO,MAAM,oBAAoB,QAAyD,CAAC"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { fileURLToPath } from "node:url";
|
|
2
|
+
export const BUILTIN_PROFILES = ["default", "development"];
|
|
3
|
+
// The launcher ships the curated plugin set, so the profile directory sits next to its build output rather than inside the runtime package.
|
|
4
|
+
export const BUILTIN_PROFILES_DIR = fileURLToPath(new URL("../profiles", import.meta.url));
|
|
5
|
+
//# sourceMappingURL=profiles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"profiles.js","sourceRoot":"","sources":["../src/profiles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,SAAS,EAAE,aAAa,CAAU,CAAC;AAEpE,4IAA4I;AAC5I,MAAM,CAAC,MAAM,oBAAoB,GAAG,aAAa,CAAC,IAAI,GAAG,CAAC,aAAa,EAAE,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pi-harness/cli",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.30",
|
|
4
4
|
"private": true,
|
|
5
5
|
"description": "Plugin-first Pi Harness CLI",
|
|
6
6
|
"homepage": "https://github.com/pi-harness/pi-harness#readme",
|
|
@@ -17,7 +17,8 @@
|
|
|
17
17
|
"pih": "./dist/bin.js"
|
|
18
18
|
},
|
|
19
19
|
"files": [
|
|
20
|
-
"dist"
|
|
20
|
+
"dist",
|
|
21
|
+
"profiles"
|
|
21
22
|
],
|
|
22
23
|
"type": "module",
|
|
23
24
|
"main": "./dist/main.js",
|