@craft_eco/craft-mcp 0.1.25 → 0.1.28
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 +33 -12
- package/bin/craft-mcp.mjs +10 -8
- package/dist-server/game-workflow/bundle-files.mjs +48 -0
- package/dist-server/game-workflow/check.mjs +3 -4
- package/dist-server/game-workflow/engines.mjs +24 -8
- package/dist-server/game-workflow/project-bundles.mjs +129 -0
- package/dist-server/game-workflow/project-context.mjs +97 -0
- package/dist-server/game-workflow/projects.mjs +22 -5
- package/dist-server/game-workflow/publication-materials.mjs +18 -20
- package/dist-server/game-workflow/publications.mjs +15 -17
- package/dist-server/game-workflow/publish-capture.mjs +21 -57
- package/dist-server/integrations/config.mjs +71 -0
- package/dist-server/integrations/files.mjs +54 -0
- package/dist-server/integrations/hosts.mjs +35 -0
- package/dist-server/integrations/install.mjs +86 -0
- package/dist-server/integrations/runtime.mjs +72 -0
- package/dist-server/mcp/publication-page.mjs +18 -50
- package/dist-server/mcp/publish-panel.mjs +28 -35
- package/dist-server/mcp/server.mjs +22 -18
- package/dist-server/mcp/start.mjs +3 -1
- package/dist-server/preview/preview-launcher.mjs +9 -2
- package/dist-server/preview/preview-start.mjs +2 -2
- package/dist-server/upstream/publication-transport.mjs +19 -19
- package/package.json +14 -8
- package/resources/craft-create/SKILL.md +11 -0
- package/resources/craft-game-maker/SKILL.md +77 -71
- package/resources/craft-game-maker/js.md +10 -10
- package/resources/craft-game-maker/js3d.md +13 -13
- package/resources/game_visual_qa.mjs +1149 -1149
- package/resources/js/bundle.json +93 -0
- package/resources/js/context/AGENTS.md +15 -102
- package/resources/js/context/knowledge/AigcWiring.md +5 -196
- package/resources/js/context/knowledge/AssetUrl.md +5 -20
- package/resources/js/context/knowledge/Layout.md +7 -0
- package/resources/js/context/knowledge/Lifecycle.md +6 -27
- package/resources/js/context/skills/aigc-generate/SKILL.md +6 -141
- package/resources/js/context/skills/asset-search/SKILL.md +5 -62
- package/resources/js/context/skills/asset-search/references/resource-config.md +9 -0
- package/resources/js/context/skills/export-config/SKILL.md +7 -19
- package/resources/js/context/skills/export-config/scripts/export-config.mjs +3 -45
- package/resources/js/context/skills/index.json +30 -0
- package/resources/js/context/skills/visual-qa/SKILL.md +6 -28
- package/resources/js/project/README.md +4 -96
- package/resources/js/project/package.json +1 -2
- package/resources/js/project/scripts/config-export/panel-resource-path.mjs +106 -0
- package/resources/js/project/scripts/config-export/sync-asset-controls.mjs +316 -0
- package/resources/js/project/scripts/config-export.mjs +10 -34
- package/resources/js3d/bundle.json +104 -0
- package/resources/js3d/context/AGENTS.md +16 -85
- package/resources/js3d/context/knowledge/AigcWiring.md +9 -0
- package/resources/js3d/context/knowledge/AssetUrl.md +9 -0
- package/resources/js3d/context/knowledge/CodingGuide/Pitfalls.md +9 -67
- package/resources/js3d/context/knowledge/Layout.md +7 -0
- package/resources/js3d/context/knowledge/Runtime.md +5 -30
- package/resources/js3d/context/skills/aigc-integration/SKILL.md +6 -164
- package/resources/js3d/context/skills/asset-search/SKILL.md +5 -171
- package/resources/js3d/context/skills/asset-search/references/resource-config.md +6 -94
- package/resources/js3d/context/skills/asset-usage-audit/SKILL.md +6 -82
- package/resources/js3d/context/skills/export-config/SKILL.md +7 -11
- package/resources/js3d/context/skills/export-config/scripts/export-config.mjs +3 -55
- package/resources/js3d/context/skills/index.json +42 -0
- package/resources/js3d/context/skills/performance-audit/SKILL.md +8 -153
- package/resources/js3d/context/skills/visual-qa/SKILL.md +14 -0
- package/resources/js3d/project/README.md +4 -103
- package/resources/js3d/project/package.json +1 -2
- package/resources/js3d/project/scripts/config-export/panel-resource-path.mjs +106 -0
- package/resources/js3d/project/scripts/config-export/sync-scene-assets.mjs +191 -0
- package/resources/js3d/project/scripts/config-export.mjs +12 -34
- package/resources/targets/codebuddy/js/bootstrap/SKILL.md +14 -0
- package/resources/targets/codebuddy/js/craft-game-maker/SKILL.md +77 -0
- package/resources/targets/codebuddy/js/craft-game-maker/js.md +10 -0
- package/resources/targets/codebuddy/js/js/bundle.json +99 -0
- package/resources/targets/codebuddy/js/js/context/AGENTS.md +25 -0
- package/resources/targets/codebuddy/js/js/context/hooks/hooks.json +14 -0
- package/resources/targets/codebuddy/js/js/context/knowledge/AigcWiring.md +9 -0
- package/resources/targets/codebuddy/js/js/context/knowledge/AssetUrl.md +9 -0
- package/resources/targets/codebuddy/js/js/context/knowledge/Layout.md +7 -0
- package/resources/targets/codebuddy/js/js/context/knowledge/Lifecycle.md +11 -0
- package/resources/targets/codebuddy/js/js/context/skills/aigc-generate/SKILL.md +14 -0
- package/resources/targets/codebuddy/js/js/context/skills/asset-search/SKILL.md +12 -0
- package/resources/targets/codebuddy/js/js/context/skills/asset-search/references/resource-config.md +9 -0
- package/resources/targets/codebuddy/js/js/context/skills/export-config/SKILL.md +16 -0
- package/resources/targets/codebuddy/js/js/context/skills/export-config/scripts/export-config.mjs +4 -0
- package/resources/targets/codebuddy/js/js/context/skills/export-config/scripts/install.mjs +89 -0
- package/resources/targets/codebuddy/js/js/context/skills/export-config/scripts/panel-resource-path.mjs +106 -0
- package/resources/targets/codebuddy/js/js/context/skills/index.json +31 -0
- package/resources/targets/codebuddy/js/js/context/skills/visual-qa/SKILL.md +14 -0
- package/resources/targets/codebuddy/js/js/project/README.md +7 -0
- package/resources/targets/codebuddy/js/js/project/configs/assets.json +1 -0
- package/resources/targets/codebuddy/js/js/project/configs/game.controls.json +3 -0
- package/resources/targets/codebuddy/js/js/project/configs/game.json +3 -0
- package/resources/targets/codebuddy/js/js/project/game.config.json +7 -0
- package/resources/targets/codebuddy/js/js/project/index.html +20 -0
- package/resources/targets/codebuddy/js/js/project/package.json +22 -0
- package/resources/targets/codebuddy/js/js/project/scripts/config-export/assert-asset-wiring.mjs +72 -0
- package/resources/targets/codebuddy/js/js/project/scripts/config-export/panel-resource-path.mjs +106 -0
- package/resources/targets/codebuddy/js/js/project/scripts/config-export/sync-asset-controls.mjs +316 -0
- package/resources/targets/codebuddy/js/js/project/scripts/config-export.mjs +13 -0
- package/resources/targets/codebuddy/js/js/project/scripts/skill-modules/export-config/cli.mjs +20 -0
- package/resources/targets/codebuddy/js/js/project/scripts/skill-modules/export-config/project.d.mts +6 -0
- package/resources/targets/codebuddy/js/js/project/scripts/skill-modules/export-config/project.mjs +77 -0
- package/resources/targets/codebuddy/js/js/project/scripts/skill-modules/export-config/vite.d.mts +2 -0
- package/resources/targets/codebuddy/js/js/project/scripts/skill-modules/export-config/vite.mjs +34 -0
- package/resources/targets/codebuddy/js/js/project/scripts/write-preview-ready.mjs +22 -0
- package/resources/targets/codebuddy/js/js/project/src/scenes/LoadScene.ts +89 -0
- package/resources/targets/codebuddy/js/js/project/src/scenes/PlayScene.ts +17 -0
- package/resources/targets/codebuddy/js/js/project/unified_data_control_config.json +20 -0
- package/resources/targets/codebuddy/js/recovery.md +7 -0
- package/resources/targets/codebuddy/js/target.json +61 -0
- package/resources/targets/codebuddy/js3d/bootstrap/SKILL.md +14 -0
- package/resources/targets/codebuddy/js3d/craft-game-maker/SKILL.md +77 -0
- package/resources/targets/codebuddy/js3d/craft-game-maker/js3d.md +13 -0
- package/resources/targets/codebuddy/js3d/js3d/bundle.json +110 -0
- package/resources/targets/codebuddy/js3d/js3d/context/AGENTS.md +26 -0
- package/resources/targets/codebuddy/js3d/js3d/context/hooks/hooks.json +14 -0
- package/resources/targets/codebuddy/js3d/js3d/context/knowledge/AigcWiring.md +9 -0
- package/resources/targets/codebuddy/js3d/js3d/context/knowledge/AssetUrl.md +9 -0
- package/resources/targets/codebuddy/js3d/js3d/context/knowledge/CodingGuide/Pitfalls.md +11 -0
- package/resources/targets/codebuddy/js3d/js3d/context/knowledge/Layout.md +7 -0
- package/resources/targets/codebuddy/js3d/js3d/context/knowledge/Runtime.md +9 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/aigc-integration/SKILL.md +14 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/asset-search/SKILL.md +12 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/asset-search/references/resource-config.md +11 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/asset-usage-audit/SKILL.md +16 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/asset-usage-audit/scripts/compare-animations.mjs +48 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/asset-usage-audit/scripts/lib/anim.mjs +266 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/asset-usage-audit/scripts/lib/glb.mjs +241 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/asset-usage-audit/scripts/lib/scan.mjs +455 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/asset-usage-audit/scripts/scan-assets.mjs +77 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/export-config/SKILL.md +16 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/export-config/assets/tooling/cli.mjs +20 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/export-config/assets/tooling/project.d.mts +6 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/export-config/assets/tooling/project.mjs +77 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/export-config/assets/tooling/vite.d.mts +2 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/export-config/assets/tooling/vite.mjs +34 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/export-config/scripts/export-config.mjs +4 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/export-config/scripts/install.mjs +89 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/export-config/scripts/panel-resource-path.mjs +106 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/index.json +43 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/performance-audit/SKILL.md +21 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/performance-audit/scripts/lib/rules.mjs +470 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/performance-audit/scripts/lib/scan.mjs +387 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/performance-audit/scripts/lib/source.mjs +398 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/performance-audit/scripts/scan-perf.mjs +130 -0
- package/resources/targets/codebuddy/js3d/js3d/context/skills/visual-qa/SKILL.md +14 -0
- package/resources/targets/codebuddy/js3d/js3d/project/README.md +7 -0
- package/resources/targets/codebuddy/js3d/js3d/project/configs/game.controls.json +3 -0
- package/resources/targets/codebuddy/js3d/js3d/project/configs/game.json +3 -0
- package/resources/targets/codebuddy/js3d/js3d/project/game-runtime.json +7 -0
- package/resources/targets/codebuddy/js3d/js3d/project/game.config.json +7 -0
- package/resources/targets/codebuddy/js3d/js3d/project/index.html +12 -0
- package/resources/targets/codebuddy/js3d/js3d/project/package.json +23 -0
- package/resources/targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform/platform.mjs +30 -0
- package/resources/targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0/release.json +24 -0
- package/resources/targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/cli.mjs +16 -0
- package/resources/targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/project.d.mts +4 -0
- package/resources/targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/project.mjs +50 -0
- package/resources/targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/vite.d.mts +3 -0
- package/resources/targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/vite.mjs +72 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/config-export/assert-asset-wiring.mjs +97 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/config-export/panel-resource-path.mjs +106 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/config-export/sync-asset-controls.mjs +327 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/config-export/sync-scene-assets.mjs +191 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/config-export.mjs +15 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/skill-modules/export-config/cli.mjs +20 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/skill-modules/export-config/config.d.mts +19 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/skill-modules/export-config/config.mjs +1 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/skill-modules/export-config/installed.json +6 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/skill-modules/export-config/project.d.mts +6 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/skill-modules/export-config/project.mjs +77 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/skill-modules/export-config/vite.d.mts +2 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/skill-modules/export-config/vite.mjs +34 -0
- package/resources/targets/codebuddy/js3d/js3d/project/scripts/write-preview-ready.mjs +22 -0
- package/resources/targets/codebuddy/js3d/js3d/project/src/main.ts +85 -0
- package/resources/targets/codebuddy/js3d/js3d/project/src/platform.ts +2 -0
- package/resources/targets/codebuddy/js3d/js3d/project/src/style.css +83 -0
- package/resources/targets/codebuddy/js3d/js3d/project/tsconfig.json +20 -0
- package/resources/targets/codebuddy/js3d/js3d/project/unified_data_control_config.json +20 -0
- package/resources/targets/codebuddy/js3d/js3d/project/vite.config.ts +5 -0
- package/resources/targets/codebuddy/js3d/recovery.md +7 -0
- package/resources/targets/codebuddy/js3d/target.json +60 -0
- package/resources/targets/codex/js/bootstrap/SKILL.md +14 -0
- package/resources/targets/codex/js/craft-game-maker/SKILL.md +77 -0
- package/resources/targets/codex/js/craft-game-maker/js.md +10 -0
- package/resources/targets/codex/js/js/bundle.json +99 -0
- package/resources/targets/codex/js/js/context/AGENTS.md +25 -0
- package/resources/targets/codex/js/js/context/hooks/hooks.json +14 -0
- package/resources/targets/codex/js/js/context/knowledge/AigcWiring.md +9 -0
- package/resources/targets/codex/js/js/context/knowledge/AssetUrl.md +9 -0
- package/resources/targets/codex/js/js/context/knowledge/Layout.md +7 -0
- package/resources/targets/codex/js/js/context/knowledge/Lifecycle.md +11 -0
- package/resources/targets/codex/js/js/context/skills/aigc-generate/SKILL.md +14 -0
- package/resources/targets/codex/js/js/context/skills/asset-search/SKILL.md +12 -0
- package/resources/targets/codex/js/js/context/skills/asset-search/references/resource-config.md +9 -0
- package/resources/targets/codex/js/js/context/skills/export-config/SKILL.md +16 -0
- package/resources/targets/codex/js/js/context/skills/export-config/assets/tooling/cli.mjs +20 -0
- package/resources/targets/codex/js/js/context/skills/export-config/assets/tooling/config.d.mts +19 -0
- package/resources/targets/codex/js/js/context/skills/export-config/assets/tooling/config.mjs +1 -0
- package/resources/targets/codex/js/js/context/skills/export-config/assets/tooling/project.d.mts +6 -0
- package/resources/targets/codex/js/js/context/skills/export-config/assets/tooling/project.mjs +77 -0
- package/resources/targets/codex/js/js/context/skills/export-config/assets/tooling/vite.d.mts +2 -0
- package/resources/targets/codex/js/js/context/skills/export-config/assets/tooling/vite.mjs +34 -0
- package/resources/targets/codex/js/js/context/skills/export-config/scripts/export-config.mjs +4 -0
- package/resources/targets/codex/js/js/context/skills/export-config/scripts/install.mjs +89 -0
- package/resources/targets/codex/js/js/context/skills/export-config/scripts/panel-resource-path.mjs +106 -0
- package/resources/targets/codex/js/js/context/skills/index.json +31 -0
- package/resources/targets/codex/js/js/context/skills/visual-qa/SKILL.md +14 -0
- package/resources/targets/codex/js/js/project/README.md +7 -0
- package/resources/targets/codex/js/js/project/configs/assets.json +1 -0
- package/resources/targets/codex/js/js/project/configs/game.controls.json +3 -0
- package/resources/targets/codex/js/js/project/configs/game.json +3 -0
- package/resources/targets/codex/js/js/project/game-runtime.json +7 -0
- package/resources/targets/codex/js/js/project/game.config.json +7 -0
- package/resources/targets/codex/js/js/project/index.html +20 -0
- package/resources/targets/codex/js/js/project/package.json +22 -0
- package/resources/targets/codex/js/js/project/runtime/lightgame/1.1.0/release.json +22 -0
- package/resources/targets/codex/js/js/project/runtime/lightgame/1.1.0/tooling/cli.mjs +16 -0
- package/resources/targets/codex/js/js/project/runtime/lightgame/1.1.0/tooling/project.d.mts +4 -0
- package/resources/targets/codex/js/js/project/runtime/lightgame/1.1.0/tooling/project.mjs +50 -0
- package/resources/targets/codex/js/js/project/runtime/lightgame/1.1.0/tooling/vite.d.mts +3 -0
- package/resources/targets/codex/js/js/project/runtime/lightgame/1.1.0/tooling/vite.mjs +72 -0
- package/resources/targets/codex/js/js/project/scripts/config-export/assert-asset-wiring.mjs +72 -0
- package/resources/targets/codex/js/js/project/scripts/config-export/panel-resource-path.mjs +106 -0
- package/resources/targets/codex/js/js/project/scripts/config-export/sync-asset-controls.mjs +316 -0
- package/resources/targets/codex/js/js/project/scripts/config-export.mjs +13 -0
- package/resources/targets/codex/js/js/project/scripts/skill-modules/export-config/cli.mjs +20 -0
- package/resources/targets/codex/js/js/project/scripts/skill-modules/export-config/config.d.mts +19 -0
- package/resources/targets/codex/js/js/project/scripts/skill-modules/export-config/config.mjs +1 -0
- package/resources/targets/codex/js/js/project/scripts/skill-modules/export-config/installed.json +6 -0
- package/resources/targets/codex/js/js/project/scripts/skill-modules/export-config/project.d.mts +6 -0
- package/resources/targets/codex/js/js/project/scripts/skill-modules/export-config/project.mjs +77 -0
- package/resources/targets/codex/js/js/project/scripts/skill-modules/export-config/vite.d.mts +2 -0
- package/resources/targets/codex/js/js/project/scripts/skill-modules/export-config/vite.mjs +34 -0
- package/resources/targets/codex/js/js/project/scripts/write-preview-ready.mjs +22 -0
- package/resources/targets/codex/js/js/project/src/main.ts +87 -0
- package/resources/targets/codex/js/js/project/src/platform.ts +2 -0
- package/resources/targets/codex/js/js/project/src/scenes/LoadScene.ts +89 -0
- package/resources/targets/codex/js/js/project/src/scenes/PlayScene.ts +17 -0
- package/resources/targets/codex/js/js/project/src/screenUi.ts +185 -0
- package/resources/targets/codex/js/js/project/src/style.css +294 -0
- package/resources/targets/codex/js/js/project/tsconfig.json +20 -0
- package/resources/targets/codex/js/js/project/unified_data_control_config.json +20 -0
- package/resources/targets/codex/js/js/project/vite.config.ts +5 -0
- package/resources/targets/codex/js/recovery.md +7 -0
- package/resources/targets/codex/js/target.json +61 -0
- package/resources/targets/codex/js3d/bootstrap/SKILL.md +14 -0
- package/resources/targets/codex/js3d/craft-game-maker/SKILL.md +77 -0
- package/resources/targets/codex/js3d/craft-game-maker/js3d.md +13 -0
- package/resources/targets/codex/js3d/js3d/bundle.json +110 -0
- package/resources/targets/codex/js3d/js3d/context/AGENTS.md +26 -0
- package/resources/targets/codex/js3d/js3d/context/hooks/hooks.json +14 -0
- package/resources/targets/codex/js3d/js3d/context/knowledge/AigcWiring.md +9 -0
- package/resources/targets/codex/js3d/js3d/context/knowledge/AssetUrl.md +9 -0
- package/resources/targets/codex/js3d/js3d/context/knowledge/CodingGuide/Pitfalls.md +11 -0
- package/resources/targets/codex/js3d/js3d/context/knowledge/Layout.md +7 -0
- package/resources/targets/codex/js3d/js3d/context/knowledge/Runtime.md +9 -0
- package/resources/targets/codex/js3d/js3d/context/skills/aigc-integration/SKILL.md +14 -0
- package/resources/targets/codex/js3d/js3d/context/skills/asset-search/SKILL.md +12 -0
- package/resources/targets/codex/js3d/js3d/context/skills/asset-search/references/resource-config.md +11 -0
- package/resources/targets/codex/js3d/js3d/context/skills/asset-usage-audit/SKILL.md +16 -0
- package/resources/targets/codex/js3d/js3d/context/skills/asset-usage-audit/scripts/compare-animations.mjs +48 -0
- package/resources/targets/codex/js3d/js3d/context/skills/asset-usage-audit/scripts/lib/anim.mjs +266 -0
- package/resources/targets/codex/js3d/js3d/context/skills/asset-usage-audit/scripts/lib/glb.mjs +241 -0
- package/resources/targets/codex/js3d/js3d/context/skills/asset-usage-audit/scripts/lib/scan.mjs +455 -0
- package/resources/targets/codex/js3d/js3d/context/skills/asset-usage-audit/scripts/scan-assets.mjs +77 -0
- package/resources/targets/codex/js3d/js3d/context/skills/export-config/SKILL.md +16 -0
- package/resources/targets/codex/js3d/js3d/context/skills/export-config/assets/tooling/cli.mjs +20 -0
- package/resources/targets/codex/js3d/js3d/context/skills/export-config/assets/tooling/config.d.mts +19 -0
- package/resources/targets/codex/js3d/js3d/context/skills/export-config/assets/tooling/config.mjs +1 -0
- package/resources/targets/codex/js3d/js3d/context/skills/export-config/assets/tooling/project.d.mts +6 -0
- package/resources/targets/codex/js3d/js3d/context/skills/export-config/assets/tooling/project.mjs +77 -0
- package/resources/targets/codex/js3d/js3d/context/skills/export-config/assets/tooling/vite.d.mts +2 -0
- package/resources/targets/codex/js3d/js3d/context/skills/export-config/assets/tooling/vite.mjs +34 -0
- package/resources/targets/codex/js3d/js3d/context/skills/export-config/scripts/export-config.mjs +4 -0
- package/resources/targets/codex/js3d/js3d/context/skills/export-config/scripts/install.mjs +89 -0
- package/resources/targets/codex/js3d/js3d/context/skills/export-config/scripts/panel-resource-path.mjs +106 -0
- package/resources/targets/codex/js3d/js3d/context/skills/index.json +43 -0
- package/resources/targets/codex/js3d/js3d/context/skills/performance-audit/SKILL.md +21 -0
- package/resources/targets/codex/js3d/js3d/context/skills/performance-audit/scripts/lib/rules.mjs +470 -0
- package/resources/targets/codex/js3d/js3d/context/skills/performance-audit/scripts/lib/scan.mjs +387 -0
- package/resources/targets/codex/js3d/js3d/context/skills/performance-audit/scripts/lib/source.mjs +398 -0
- package/resources/targets/codex/js3d/js3d/context/skills/performance-audit/scripts/scan-perf.mjs +130 -0
- package/resources/targets/codex/js3d/js3d/context/skills/visual-qa/SKILL.md +14 -0
- package/resources/targets/codex/js3d/js3d/project/README.md +7 -0
- package/resources/targets/codex/js3d/js3d/project/configs/game.controls.json +3 -0
- package/resources/targets/codex/js3d/js3d/project/configs/game.json +3 -0
- package/resources/targets/codex/js3d/js3d/project/game-runtime.json +7 -0
- package/resources/targets/codex/js3d/js3d/project/game.config.json +7 -0
- package/resources/targets/codex/js3d/js3d/project/index.html +12 -0
- package/resources/targets/codex/js3d/js3d/project/package.json +23 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/platform/identity/qq-ai-game-sdk.min.js +5 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/platform/identity/qq-session.mjs +208 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/platform/identity/shared.mjs +37 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/platform/platform-capture-video.mjs +227 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/platform/platform-service.d.mts +31 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/platform/platform-service.mjs +272 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/platform/platform.d.mts +79 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/platform/platform.mjs +30 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/release.json +24 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/cli.mjs +16 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/project.d.mts +4 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/project.mjs +50 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/vite.d.mts +3 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/vite.mjs +72 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/tools/assets.d.mts +24 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/tools/assets.mjs +2 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/tools/astc.d.mts +10 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/tools/astc.mjs +1 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/tools/glb.d.mts +26 -0
- package/resources/targets/codex/js3d/js3d/project/runtime/lightgame/1.1.0/tools/glb.mjs +351 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/config-export/assert-asset-wiring.mjs +97 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/config-export/panel-resource-path.mjs +106 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/config-export/sync-asset-controls.mjs +327 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/config-export/sync-scene-assets.mjs +191 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/config-export.mjs +15 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/skill-modules/export-config/cli.mjs +20 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/skill-modules/export-config/config.d.mts +19 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/skill-modules/export-config/config.mjs +1 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/skill-modules/export-config/installed.json +6 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/skill-modules/export-config/project.d.mts +6 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/skill-modules/export-config/project.mjs +77 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/skill-modules/export-config/vite.d.mts +2 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/skill-modules/export-config/vite.mjs +34 -0
- package/resources/targets/codex/js3d/js3d/project/scripts/write-preview-ready.mjs +22 -0
- package/resources/targets/codex/js3d/js3d/project/src/display/ui-stage.ts +156 -0
- package/resources/targets/codex/js3d/js3d/project/src/display/viewport.ts +239 -0
- package/resources/targets/codex/js3d/js3d/project/src/main.ts +85 -0
- package/resources/targets/codex/js3d/js3d/project/src/platform.ts +2 -0
- package/resources/targets/codex/js3d/js3d/project/src/style.css +83 -0
- package/resources/targets/codex/js3d/js3d/project/tsconfig.json +20 -0
- package/resources/targets/codex/js3d/js3d/project/unified_data_control_config.json +20 -0
- package/resources/targets/codex/js3d/js3d/project/vite.config.ts +5 -0
- package/resources/targets/codex/js3d/recovery.md +7 -0
- package/resources/targets/codex/js3d/target.json +60 -0
- package/resources/targets/index.json +41 -0
- package/resources/targets/workbuddy/js/bootstrap/SKILL.md +14 -0
- package/resources/targets/workbuddy/js/craft-game-maker/SKILL.md +77 -0
- package/resources/targets/workbuddy/js/craft-game-maker/js.md +10 -0
- package/resources/targets/workbuddy/js/js/bundle.json +99 -0
- package/resources/targets/workbuddy/js/js/context/AGENTS.md +25 -0
- package/resources/targets/workbuddy/js/js/context/hooks/hooks.json +14 -0
- package/resources/targets/workbuddy/js/js/context/knowledge/AigcWiring.md +9 -0
- package/resources/targets/workbuddy/js/js/context/knowledge/AssetUrl.md +9 -0
- package/resources/targets/workbuddy/js/js/context/knowledge/Layout.md +7 -0
- package/resources/targets/workbuddy/js/js/context/knowledge/Lifecycle.md +11 -0
- package/resources/targets/workbuddy/js/js/context/skills/aigc-generate/SKILL.md +14 -0
- package/resources/targets/workbuddy/js/js/context/skills/asset-search/SKILL.md +12 -0
- package/resources/targets/workbuddy/js/js/context/skills/asset-search/references/resource-config.md +9 -0
- package/resources/targets/workbuddy/js/js/context/skills/export-config/SKILL.md +16 -0
- package/resources/targets/workbuddy/js/js/context/skills/export-config/assets/tooling/cli.mjs +20 -0
- package/resources/targets/workbuddy/js/js/context/skills/export-config/assets/tooling/config.d.mts +19 -0
- package/resources/targets/workbuddy/js/js/context/skills/export-config/assets/tooling/config.mjs +1 -0
- package/resources/targets/workbuddy/js/js/context/skills/export-config/assets/tooling/project.d.mts +6 -0
- package/resources/targets/workbuddy/js/js/context/skills/export-config/assets/tooling/project.mjs +77 -0
- package/resources/targets/workbuddy/js/js/context/skills/export-config/assets/tooling/vite.d.mts +2 -0
- package/resources/targets/workbuddy/js/js/context/skills/export-config/assets/tooling/vite.mjs +34 -0
- package/resources/targets/workbuddy/js/js/context/skills/export-config/scripts/export-config.mjs +4 -0
- package/resources/targets/workbuddy/js/js/context/skills/export-config/scripts/install.mjs +89 -0
- package/resources/targets/workbuddy/js/js/context/skills/export-config/scripts/panel-resource-path.mjs +106 -0
- package/resources/targets/workbuddy/js/js/context/skills/index.json +31 -0
- package/resources/targets/workbuddy/js/js/context/skills/visual-qa/SKILL.md +14 -0
- package/resources/targets/workbuddy/js/js/project/README.md +7 -0
- package/resources/targets/workbuddy/js/js/project/configs/assets.json +1 -0
- package/resources/targets/workbuddy/js/js/project/configs/game.controls.json +3 -0
- package/resources/targets/workbuddy/js/js/project/configs/game.json +3 -0
- package/resources/targets/workbuddy/js/js/project/game-runtime.json +7 -0
- package/resources/targets/workbuddy/js/js/project/game.config.json +7 -0
- package/resources/targets/workbuddy/js/js/project/index.html +20 -0
- package/resources/targets/workbuddy/js/js/project/package.json +22 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/platform/identity/qq-ai-game-sdk.min.js +5 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/platform/identity/qq-session.mjs +208 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/platform/identity/shared.mjs +37 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/platform/platform-capture-video.mjs +227 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/platform/platform-service.d.mts +31 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/platform/platform-service.mjs +272 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/platform/platform.d.mts +79 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/platform/platform.mjs +29 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/release.json +22 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/tooling/cli.mjs +16 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/tooling/project.d.mts +4 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/tooling/project.mjs +50 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/tooling/vite.d.mts +3 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/tooling/vite.mjs +72 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/tools/assets.d.mts +24 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/tools/assets.mjs +2 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/tools/astc.d.mts +10 -0
- package/resources/targets/workbuddy/js/js/project/runtime/lightgame/1.1.0/tools/astc.mjs +1 -0
- package/resources/targets/workbuddy/js/js/project/scripts/config-export/assert-asset-wiring.mjs +72 -0
- package/resources/targets/workbuddy/js/js/project/scripts/config-export/panel-resource-path.mjs +106 -0
- package/resources/targets/workbuddy/js/js/project/scripts/config-export/sync-asset-controls.mjs +316 -0
- package/resources/targets/workbuddy/js/js/project/scripts/config-export.mjs +13 -0
- package/resources/targets/workbuddy/js/js/project/scripts/skill-modules/export-config/cli.mjs +20 -0
- package/resources/targets/workbuddy/js/js/project/scripts/skill-modules/export-config/config.d.mts +19 -0
- package/resources/targets/workbuddy/js/js/project/scripts/skill-modules/export-config/config.mjs +1 -0
- package/resources/targets/workbuddy/js/js/project/scripts/skill-modules/export-config/installed.json +6 -0
- package/resources/targets/workbuddy/js/js/project/scripts/skill-modules/export-config/project.d.mts +6 -0
- package/resources/targets/workbuddy/js/js/project/scripts/skill-modules/export-config/project.mjs +77 -0
- package/resources/targets/workbuddy/js/js/project/scripts/skill-modules/export-config/vite.d.mts +2 -0
- package/resources/targets/workbuddy/js/js/project/scripts/skill-modules/export-config/vite.mjs +34 -0
- package/resources/targets/workbuddy/js/js/project/scripts/write-preview-ready.mjs +22 -0
- package/resources/targets/workbuddy/js/js/project/src/display/ui-stage.ts +156 -0
- package/resources/targets/workbuddy/js/js/project/src/display/viewport.ts +249 -0
- package/resources/targets/workbuddy/js/js/project/src/main.ts +87 -0
- package/resources/targets/workbuddy/js/js/project/src/platform.ts +2 -0
- package/resources/targets/workbuddy/js/js/project/src/scenes/LoadScene.ts +89 -0
- package/resources/targets/workbuddy/js/js/project/src/scenes/PlayScene.ts +17 -0
- package/resources/targets/workbuddy/js/js/project/src/screenUi.ts +185 -0
- package/resources/targets/workbuddy/js/js/project/src/style.css +294 -0
- package/resources/targets/workbuddy/js/js/project/tsconfig.json +20 -0
- package/resources/targets/workbuddy/js/js/project/unified_data_control_config.json +20 -0
- package/resources/targets/workbuddy/js/js/project/vite.config.ts +5 -0
- package/resources/targets/workbuddy/js/recovery.md +7 -0
- package/resources/targets/workbuddy/js/target.json +61 -0
- package/resources/targets/workbuddy/js3d/bootstrap/SKILL.md +14 -0
- package/resources/targets/workbuddy/js3d/craft-game-maker/SKILL.md +77 -0
- package/resources/targets/workbuddy/js3d/craft-game-maker/js3d.md +13 -0
- package/resources/targets/workbuddy/js3d/js3d/bundle.json +110 -0
- package/resources/targets/workbuddy/js3d/js3d/context/AGENTS.md +26 -0
- package/resources/targets/workbuddy/js3d/js3d/context/hooks/hooks.json +14 -0
- package/resources/targets/workbuddy/js3d/js3d/context/knowledge/AigcWiring.md +9 -0
- package/resources/targets/workbuddy/js3d/js3d/context/knowledge/AssetUrl.md +9 -0
- package/resources/targets/workbuddy/js3d/js3d/context/knowledge/CodingGuide/Pitfalls.md +11 -0
- package/resources/targets/workbuddy/js3d/js3d/context/knowledge/Layout.md +7 -0
- package/resources/targets/workbuddy/js3d/js3d/context/knowledge/Runtime.md +9 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/aigc-integration/SKILL.md +14 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/asset-search/SKILL.md +12 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/asset-search/references/resource-config.md +11 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/asset-usage-audit/SKILL.md +16 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/asset-usage-audit/scripts/compare-animations.mjs +48 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/asset-usage-audit/scripts/lib/anim.mjs +266 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/asset-usage-audit/scripts/lib/glb.mjs +241 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/asset-usage-audit/scripts/lib/scan.mjs +455 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/asset-usage-audit/scripts/scan-assets.mjs +77 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/export-config/SKILL.md +16 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/export-config/assets/tooling/cli.mjs +20 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/export-config/assets/tooling/config.d.mts +19 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/export-config/assets/tooling/config.mjs +1 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/export-config/assets/tooling/project.d.mts +6 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/export-config/assets/tooling/project.mjs +77 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/export-config/assets/tooling/vite.d.mts +2 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/export-config/assets/tooling/vite.mjs +34 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/export-config/scripts/export-config.mjs +4 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/export-config/scripts/install.mjs +89 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/export-config/scripts/panel-resource-path.mjs +106 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/index.json +43 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/performance-audit/SKILL.md +21 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/performance-audit/scripts/lib/rules.mjs +470 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/performance-audit/scripts/lib/scan.mjs +387 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/performance-audit/scripts/lib/source.mjs +398 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/performance-audit/scripts/scan-perf.mjs +130 -0
- package/resources/targets/workbuddy/js3d/js3d/context/skills/visual-qa/SKILL.md +14 -0
- package/resources/targets/workbuddy/js3d/js3d/project/README.md +7 -0
- package/resources/targets/workbuddy/js3d/js3d/project/configs/game.controls.json +3 -0
- package/resources/targets/workbuddy/js3d/js3d/project/configs/game.json +3 -0
- package/resources/targets/workbuddy/js3d/js3d/project/game-runtime.json +7 -0
- package/resources/targets/workbuddy/js3d/js3d/project/game.config.json +7 -0
- package/resources/targets/workbuddy/js3d/js3d/project/index.html +12 -0
- package/resources/targets/workbuddy/js3d/js3d/project/package.json +23 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform/identity/qq-ai-game-sdk.min.js +5 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform/identity/qq-session.mjs +208 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform/identity/shared.mjs +37 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform/platform-capture-video.mjs +227 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform/platform-service.d.mts +31 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform/platform-service.mjs +272 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform/platform.d.mts +79 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform/platform.mjs +30 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/release.json +24 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/cli.mjs +16 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/project.d.mts +4 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/project.mjs +50 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/vite.d.mts +3 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tooling/vite.mjs +72 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tools/assets.d.mts +24 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tools/assets.mjs +2 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tools/astc.d.mts +10 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tools/astc.mjs +1 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tools/glb.d.mts +26 -0
- package/resources/targets/workbuddy/js3d/js3d/project/runtime/lightgame/1.1.0/tools/glb.mjs +351 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/config-export/assert-asset-wiring.mjs +97 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/config-export/panel-resource-path.mjs +106 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/config-export/sync-asset-controls.mjs +327 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/config-export/sync-scene-assets.mjs +191 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/config-export.mjs +15 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/skill-modules/export-config/cli.mjs +20 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/skill-modules/export-config/config.d.mts +19 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/skill-modules/export-config/config.mjs +1 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/skill-modules/export-config/installed.json +6 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/skill-modules/export-config/project.d.mts +6 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/skill-modules/export-config/project.mjs +77 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/skill-modules/export-config/vite.d.mts +2 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/skill-modules/export-config/vite.mjs +34 -0
- package/resources/targets/workbuddy/js3d/js3d/project/scripts/write-preview-ready.mjs +22 -0
- package/resources/targets/workbuddy/js3d/js3d/project/src/display/ui-stage.ts +156 -0
- package/resources/targets/workbuddy/js3d/js3d/project/src/display/viewport.ts +239 -0
- package/resources/targets/workbuddy/js3d/js3d/project/src/main.ts +85 -0
- package/resources/targets/workbuddy/js3d/js3d/project/src/platform.ts +2 -0
- package/resources/targets/workbuddy/js3d/js3d/project/src/style.css +83 -0
- package/resources/targets/workbuddy/js3d/js3d/project/tsconfig.json +20 -0
- package/resources/targets/workbuddy/js3d/js3d/project/unified_data_control_config.json +20 -0
- package/resources/targets/workbuddy/js3d/js3d/project/vite.config.ts +5 -0
- package/resources/targets/workbuddy/js3d/recovery.md +7 -0
- package/resources/targets/workbuddy/js3d/target.json +60 -0
- package/vendor/craft-runtime/NOTICE.md +3 -0
- package/vendor/craft-runtime/SOURCE.json +63 -0
- package/vendor/craft-runtime/index.js +1716 -0
- package/vendor/craft-runtime/isolated-launcher.js +94 -0
- package/vendor/craft-runtime/isolated-preload.js +80 -0
- package/vendor/craft-runtime/package.json +8 -0
- package/resources/js/context/.role/AGENTS_DESIGN.md +0 -9
- package/resources/js/context/agents/aigc-asset.md +0 -168
- package/resources/js/context/knowledge/AigcEnabled.md +0 -49
- package/resources/js/context/knowledge/FrontendComponents.md +0 -17
- package/resources/js/context/knowledge/MobileAdaptation.md +0 -73
- package/resources/js/context/knowledge/MobileAdapted.md +0 -36
- package/resources/js/context/knowledge/Multiplayer/GameplaySystemKnowledge.md +0 -114
- package/resources/js/context/knowledge/Multiplayer/OverviewKnowledge.md +0 -115
- package/resources/js/context/knowledge/Multiplayer/StateSyncKnowledge.md +0 -392
- package/resources/js/context/knowledge/PlatformServices.md +0 -190
- package/resources/js/context/knowledge/ProjectDisplayConfig.md +0 -35
- package/resources/js/context/knowledge/Subsystems/Optional/MultiplayerManagerKnowledge.md +0 -242
- package/resources/js/context/knowledge/Ui.md +0 -11
- package/resources/js/context/knowledge/UiEditorCompat.md +0 -21
- package/resources/js/context/rules/MultiplayerCapability.md +0 -23
- package/resources/js/context/rules/MultiplayerRoomEntryUX.md +0 -63
- package/resources/js/context/rules/PlatformBoundaryModules.md +0 -44
- package/resources/js/context/rules/preview_ready.md +0 -8
- package/resources/js/context/skills/aigc-generate/knowledge/audio.md +0 -39
- package/resources/js/context/skills/aigc-generate/knowledge/batch-replace.md +0 -26
- package/resources/js/context/skills/aigc-generate/knowledge/character2d.md +0 -132
- package/resources/js/context/skills/aigc-generate/knowledge/non-stepwise-aigc.md +0 -53
- package/resources/js/context/skills/aigc-generate/knowledge/texture-prop.md +0 -52
- package/resources/js/context/skills/aigc-generate/knowledge/texture-scene.md +0 -191
- package/resources/js/context/skills/aigc-generate/knowledge/texture-ui.md +0 -55
- package/resources/js/context/skills/asset-search/scripts/asset_display.mjs +0 -62
- package/resources/js/context/skills/asset-search/scripts/config.json +0 -5
- package/resources/js/context/skills/asset-search/scripts/provided_assets.mjs +0 -125
- package/resources/js/context/skills/asset-search/scripts/search.mjs +0 -760
- package/resources/js/context/skills/asset-search/scripts/sprite_source_materializer.mjs +0 -657
- package/resources/js/context/skills/asset-search/strategies/anim2d.md +0 -42
- package/resources/js/context/skills/asset-search/strategies/audio.md +0 -34
- package/resources/js/context/skills/asset-search/strategies/effect2d.md +0 -31
- package/resources/js/context/skills/asset-search/strategies/texture-prop.md +0 -22
- package/resources/js/context/skills/asset-search/strategies/ui-common.md +0 -40
- package/resources/js/context/skills/asset-search/strategies/ui-style.md +0 -28
- package/resources/js/context/skills/export-config/scripts/sync-asset-controls.mjs +0 -352
- package/resources/js/context/skills/export-config/scripts/translate-asset-titles.mjs +0 -161
- package/resources/js/context/skills/lightgame-runtime-adapt/SKILL.md +0 -93
- package/resources/js/context/skills/lightgame-runtime-adapt/project/package.json +0 -22
- package/resources/js/context/skills/lightgame-runtime-adapt/project/scripts/config-export.mjs +0 -37
- package/resources/js/context/skills/lightgame-runtime-adapt/project/scripts/refresh-runtime.mjs +0 -50
- package/resources/js/context/skills/lightgame-runtime-adapt/scripts/install-template.mjs +0 -159
- package/resources/js/context/skills/mobile-adaptation/SKILL.md +0 -277
- package/resources/js/context/skills/mobile-adaptation/assets/example/src/input/input-config.json +0 -50
- package/resources/js/context/skills/mobile-adaptation/assets/example/src/input/input-layer.ts +0 -862
- package/resources/js/context/skills/mobile-adaptation/assets/example/src/input/input-platform.ts +0 -92
- package/resources/js/context/skills/mobile-adaptation/assets/example/src/input/input-primitives.ts +0 -254
- package/resources/js/context/skills/mobile-adaptation/assets/example/src/input/look-pad.ts +0 -245
- package/resources/js/context/skills/mobile-adaptation/assets/example/src/ui/touch-controls.css +0 -135
- package/resources/js/context/skills/mobile-adaptation/references/input-config.md +0 -342
- package/resources/js/context/skills/mobile-adaptation/references/verification.md +0 -140
- package/resources/js/context/skills/mobile-adaptation/references/web-audio.md +0 -11
- package/resources/js/context/skills/mobile-compat-qa/SKILL.md +0 -53
- package/resources/js/context/skills/mobile-compat-qa/references/startup-diagnosis.md +0 -23
- package/resources/js/context/skills/mobile-compat-qa/references/web-lifecycle.md +0 -20
- package/resources/js/context/skills/mobile-compat-qa/references/web-performance.md +0 -19
- package/resources/js/context/skills/optimization-suggestions/SKILL.md +0 -89
- package/resources/js/context/skills/platform-services/SKILL.md +0 -101
- package/resources/js/context/skills/platform-services/assets/modules/MultiplayerManager.ts +0 -465
- package/resources/js/context/skills/platform-services/assets/modules/eventBus.ts +0 -57
- package/resources/js/context/skills/platform-services/assets/modules/leaderboard.d.mts +0 -39
- package/resources/js/context/skills/platform-services/assets/modules/leaderboard.mjs +0 -1
- package/resources/js/context/skills/platform-services/assets/modules/log.ts +0 -35
- package/resources/js/context/skills/platform-services/assets/modules/multiplayer/clockSync.ts +0 -61
- package/resources/js/context/skills/platform-services/assets/modules/multiplayer/dsClient.ts +0 -52
- package/resources/js/context/skills/platform-services/assets/modules/multiplayer/payloadCodec.ts +0 -30
- package/resources/js/context/skills/platform-services/assets/modules/multiplayer/roomHttp.ts +0 -89
- package/resources/js/context/skills/platform-services/assets/modules/multiplayer/types.ts +0 -47
- package/resources/js/context/skills/platform-services/assets/modules/save.d.mts +0 -49
- package/resources/js/context/skills/platform-services/assets/modules/save.mjs +0 -1
- package/resources/js/context/skills/platform-services/assets/scaffold/ds/main.mjs +0 -7
- package/resources/js/context/skills/platform-services/assets/scaffold/ds/rooms/SyncRoom.mjs +0 -264
- package/resources/js/context/skills/platform-services/assets/scaffold/ds/rooms/syncSchema.mjs +0 -39
- package/resources/js/context/skills/platform-services/references/SERVER_GUIDE.md +0 -139
- package/resources/js/context/skills/platform-services/references/api_reference.md +0 -18
- package/resources/js/context/skills/platform-services/references/leaderboard_playbook.md +0 -96
- package/resources/js/context/skills/platform-services/scripts/install.mjs +0 -148
- package/resources/js/context/skills/resolution-adaptation/SKILL.md +0 -47
- package/resources/js/context/skills/resolution-adaptation/assets/example/main.ts +0 -98
- package/resources/js/context/skills/resolution-adaptation/assets/example/ui-tokens.css +0 -200
- package/resources/js/context/skills/resolution-adaptation/references/audit.md +0 -31
- package/resources/js/context/skills/resolution-adaptation/references/device-safe-area.md +0 -40
- package/resources/js/context/skills/resolution-adaptation/references/game-ui-occlusion.md +0 -18
- package/resources/js/context/skills/resolution-adaptation/references/layout-rules.md +0 -15
- package/resources/js/context/skills/resolution-adaptation/references/troubleshooting.md +0 -34
- package/resources/js/context/skills/resolution-adaptation/references/viewport-api.md +0 -38
- package/resources/js/context/skills/resolution-adaptation/references/world-resize.md +0 -55
- package/resources/js/context/skills/resolution-adaptation/scripts/aspect_audit.mjs +0 -448
- package/resources/js/context/skills/scene-editor-compat/SKILL.md +0 -94
- package/resources/js/context/skills/scene-editor-compat/assets/example/localcraft.assets.json +0 -13
- package/resources/js/context/skills/scene-editor-compat/assets/example/localcraft.scene-editor.json +0 -6
- package/resources/js/context/skills/scene-editor-compat/assets/example/src/game/sceneAdapter.ts +0 -25
- package/resources/js/context/skills/scene-editor-compat/assets/example/src/scenes/main.scene.json +0 -18
- package/resources/js/context/skills/scene-editor-compat/assets/runtime/release.json +0 -7
- package/resources/js/context/skills/scene-editor-compat/assets/runtime/scene.d.mts +0 -42
- package/resources/js/context/skills/scene-editor-compat/assets/runtime/scene.mjs +0 -144
- package/resources/js/context/skills/scene-editor-compat/docs/contract.md +0 -330
- package/resources/js/context/skills/scene-editor-compat/docs/resource-sync.md +0 -64
- package/resources/js/context/skills/scene-editor-compat/docs/runtime-state.md +0 -28
- package/resources/js/context/skills/scene-editor-compat/docs/terrain-contract.md +0 -47
- package/resources/js/context/skills/scene-editor-compat/docs/visual-contract.md +0 -64
- package/resources/js/context/skills/scene-editor-compat/examples/platformer-ts/localcraft.assets.json +0 -38
- package/resources/js/context/skills/scene-editor-compat/examples/platformer-ts/localcraft.scene-editor.json +0 -9
- package/resources/js/context/skills/scene-editor-compat/examples/platformer-ts/src/game/sceneAdapter.ts +0 -59
- package/resources/js/context/skills/scene-editor-compat/examples/platformer-ts/src/game/sceneBlockers.ts +0 -30
- package/resources/js/context/skills/scene-editor-compat/examples/platformer-ts/src/game/sceneFileAssets.ts +0 -66
- package/resources/js/context/skills/scene-editor-compat/examples/platformer-ts/src/scenes/Main.Scene.ts +0 -20
- package/resources/js/context/skills/scene-editor-compat/examples/platformer-ts/src/scenes/SceneTypes.ts +0 -26
- package/resources/js/context/skills/scene-editor-compat/references/contract.md +0 -73
- package/resources/js/context/skills/scene-editor-compat/scripts/apply_scene_marker.py +0 -162
- package/resources/js/context/skills/scene-editor-compat/scripts/check_scene_contract.py +0 -853
- package/resources/js/context/skills/scene-editor-compat/scripts/check_scene_resource_urls.py +0 -173
- package/resources/js/context/skills/scene-editor-compat/scripts/scene-editor.mjs +0 -427
- package/resources/js/context/skills/scene-editor-compat/version.json +0 -1
- package/resources/js/context/skills/ui-editor-compat/SKILL.md +0 -48
- package/resources/js/context/skills/ui-editor-compat/assets/example/hud/WidgetLayout_Hud.ts +0 -35
- package/resources/js/context/skills/ui-editor-compat/assets/example/hud/WidgetLogic_Hud.ts +0 -74
- package/resources/js/context/skills/ui-editor-compat/assets/example/hud/hud.css +0 -60
- package/resources/js/context/skills/ui-editor-compat/assets/runtime/dom-ui.d.mts +0 -45
- package/resources/js/context/skills/ui-editor-compat/assets/runtime/dom-ui.mjs +0 -265
- package/resources/js/context/skills/ui-editor-compat/assets/runtime/release.json +0 -7
- package/resources/js/context/skills/ui-editor-compat/references/contract.md +0 -132
- package/resources/js/context/skills/ui-editor-compat/scripts/editor-contract.mjs +0 -327
- package/resources/js/context/skills/ui-editor-compat/scripts/project-files.mjs +0 -80
- package/resources/js/context/skills/ui-editor-compat/scripts/ui-editor.mjs +0 -84
- package/resources/js/context/skills/version-update/SKILL.md +0 -192
- package/resources/js/context/skills/version-update/scripts/check_runtime_refs.mjs +0 -129
- package/resources/js/context/skills/version-update/scripts/feature_snapshot.mjs +0 -159
- package/resources/js/context/skills/version-update/scripts/update_feature_version.mjs +0 -157
- package/resources/js/context/skills/version-update/upgrade_diffs/.gitkeep +0 -0
- package/resources/js/context/version/version.json +0 -1
- package/resources/js/project/SPEC/assist/.gitkeep +0 -0
- package/resources/js/project/SPEC/guide/.gitkeep +0 -0
- package/resources/js/project/SPEC/plan/.gitkeep +0 -0
- package/resources/js/project/SPEC/readme.md +0 -6
- package/resources/js/project/SPEC/res/.gitkeep +0 -0
- package/resources/js/project/SPEC/task-item/.gitkeep +0 -0
- package/resources/js/project/runtime/lightgame/1.0.0/platform/leaderboard.d.mts +0 -39
- package/resources/js/project/runtime/lightgame/1.0.0/platform/leaderboard.mjs +0 -1
- package/resources/js/project/runtime/lightgame/1.0.0/platform/platform-service.d.mts +0 -25
- package/resources/js/project/runtime/lightgame/1.0.0/platform/platform-service.mjs +0 -1
- package/resources/js/project/runtime/lightgame/1.0.0/platform/save.d.mts +0 -49
- package/resources/js/project/runtime/lightgame/1.0.0/platform/save.mjs +0 -1
- package/resources/js/project/runtime/lightgame/1.0.0/release.json +0 -37
- package/resources/js/project/runtime/lightgame/1.0.0/tooling/cli.mjs +0 -2
- package/resources/js/project/runtime/lightgame/1.0.0/tooling/project.d.mts +0 -8
- package/resources/js/project/runtime/lightgame/1.0.0/tooling/project.mjs +0 -2
- package/resources/js/project/runtime/lightgame/1.0.0/tooling/vite.d.mts +0 -3
- package/resources/js/project/runtime/lightgame/1.0.0/tooling/vite.mjs +0 -8
- package/resources/js/project/runtime/lightgame/1.0.0/tools/audio.d.mts +0 -20
- package/resources/js/project/runtime/lightgame/1.0.0/tools/audio.mjs +0 -1
- package/resources/js/project/runtime/lightgame/1.0.0/tools/canvas.d.mts +0 -21
- package/resources/js/project/runtime/lightgame/1.0.0/tools/canvas.mjs +0 -1
- package/resources/js/project/runtime/lightgame/1.0.0/tools/input.d.mts +0 -17
- package/resources/js/project/runtime/lightgame/1.0.0/tools/input.mjs +0 -1
- package/resources/js/project/runtime/lightgame/1.0.0/tools/three.d.mts +0 -40
- package/resources/js/project/runtime/lightgame/1.0.0/tools/three.mjs +0 -1
- package/resources/js/project/runtime/lightgame/1.0.0/tools/ui.d.mts +0 -10
- package/resources/js/project/runtime/lightgame/1.0.0/tools/ui.mjs +0 -1
- package/resources/js/project/runtime/lightgame/1.0.0/tools/video.d.mts +0 -8
- package/resources/js/project/runtime/lightgame/1.0.0/tools/video.mjs +0 -1
- package/resources/js/project/scripts/refresh-runtime.mjs +0 -50
- package/resources/js/project/vendor/core-manager-js/package.json +0 -33
- package/resources/js/project/vendor/core-manager-js/src/.versions.json +0 -42
- package/resources/js/project/vendor/core-manager-js/src/CoreManagerPlugin.ts +0 -41
- package/resources/js/project/vendor/core-manager-js/src/assetManager/AssetRef.ts +0 -93
- package/resources/js/project/vendor/core-manager-js/src/assetManager/AstcFirstImageFile.ts +0 -203
- package/resources/js/project/vendor/core-manager-js/src/assetManager/AstcTextureLoader.ts +0 -106
- package/resources/js/project/vendor/core-manager-js/src/assetManager/resolveAssetUrl.test.ts +0 -25
- package/resources/js/project/vendor/core-manager-js/src/assetManager/resolveAssetUrl.ts +0 -21
- package/resources/js/project/vendor/core-manager-js/src/audioManager/AudioManager.test.ts +0 -65
- package/resources/js/project/vendor/core-manager-js/src/audioManager/AudioManager.ts +0 -340
- package/resources/js/project/vendor/core-manager-js/src/configManager/FeatureConfig.ts +0 -87
- package/resources/js/project/vendor/core-manager-js/src/configManager/tuneRuntime.d.mts +0 -92
- package/resources/js/project/vendor/core-manager-js/src/configManager/tuneRuntime.mjs +0 -271
- package/resources/js/project/vendor/core-manager-js/src/index.ts +0 -31
- package/resources/js/project/vendor/core-manager-js/src/inputManager/InputConfig.ts +0 -81
- package/resources/js/project/vendor/core-manager-js/src/inputManager/InputManager.test.ts +0 -43
- package/resources/js/project/vendor/core-manager-js/src/inputManager/InputManager.ts +0 -32
- package/resources/js/project/vendor/core-manager-js/src/inputManager/InputRuntime.test.ts +0 -141
- package/resources/js/project/vendor/core-manager-js/src/inputManager/InputRuntime.ts +0 -20
- package/resources/js/project/vendor/core-manager-js/src/inputManager/KeyboardProvider.ts +0 -183
- package/resources/js/project/vendor/core-manager-js/src/inputManager/TouchProvider.ts +0 -304
- package/resources/js/project/vendor/core-manager-js/src/inputManager/VirtualJoystick.ts +0 -351
- package/resources/js/project/vendor/core-manager-js/src/inputManager/_internal/InputManagerImpl.ts +0 -180
- package/resources/js/project/vendor/core-manager-js/src/inputManager/icons.b64 +0 -13
- package/resources/js/project/vendor/core-manager-js/src/inputManager/icons.b64.d.ts +0 -14
- package/resources/js/project/vendor/core-manager-js/src/inputManager/input_config.example.json +0 -68
- package/resources/js/project/vendor/core-manager-js/src/logManager/DebugConsole.ts +0 -433
- package/resources/js/project/vendor/core-manager-js/src/logManager/LogCapture.ts +0 -118
- package/resources/js/project/vendor/core-manager-js/src/logManager/LogManager.ts +0 -444
- package/resources/js/project/vendor/core-manager-js/src/logManager/ScreenCapture.ts +0 -485
- package/resources/js/project/vendor/core-manager-js/src/logManager/ScreenCaptureVideo.test.ts +0 -66
- package/resources/js/project/vendor/core-manager-js/src/logManager/ScreenCaptureVideo.ts +0 -149
- package/resources/js/project/vendor/core-manager-js/src/logManager/icons.b64 +0 -9
- package/resources/js/project/vendor/core-manager-js/src/resourceManager/AssetUrlResolver.ts +0 -29
- package/resources/js/project/vendor/core-manager-js/src/resourceManager/ResourceManager.test.ts +0 -88
- package/resources/js/project/vendor/core-manager-js/src/resourceManager/ResourceManager.ts +0 -122
- package/resources/js/project/vendor/core-manager-js/src/runtime.ts +0 -24
- package/resources/js/project/vendor/core-manager-js/src/spriteAnimManager/CharacterEntity.ts +0 -318
- package/resources/js/project/vendor/core-manager-js/src/spriteAnimManager/CharacterPhysicsBinding.test.ts +0 -151
- package/resources/js/project/vendor/core-manager-js/src/spriteAnimManager/CharacterPhysicsBinding.ts +0 -235
- package/resources/js/project/vendor/core-manager-js/src/spriteAnimManager/EffectComposite.test.ts +0 -98
- package/resources/js/project/vendor/core-manager-js/src/spriteAnimManager/EffectComposite.ts +0 -94
- package/resources/js/project/vendor/core-manager-js/src/spriteAnimManager/EffectEntity.ts +0 -209
- package/resources/js/project/vendor/core-manager-js/src/spriteAnimManager/FxManager.test.ts +0 -106
- package/resources/js/project/vendor/core-manager-js/src/spriteAnimManager/FxManager.ts +0 -341
- package/resources/js/project/vendor/core-manager-js/src/spriteAnimManager/FxRecipe.test.ts +0 -68
- package/resources/js/project/vendor/core-manager-js/src/spriteAnimManager/FxRecipe.ts +0 -236
- package/resources/js/project/vendor/core-manager-js/src/spriteAnimManager/SpriteAnimManager.test.ts +0 -22
- package/resources/js/project/vendor/core-manager-js/src/spriteAnimManager/SpriteAnimManager.ts +0 -29
- package/resources/js/project/vendor/core-manager-js/src/spriteAnimManager/SpriteEntity.test.ts +0 -197
- package/resources/js/project/vendor/core-manager-js/src/uiManager/DomUiContracts.ts +0 -9
- package/resources/js/project/vendor/core-manager-js/src/uiManager/DomUiKit.ts +0 -555
- package/resources/js/project/vendor/core-manager-js/src/uiManager/UIFacadePlugin.test.ts +0 -112
- package/resources/js/project/vendor/core-manager-js/src/uiManager/UIFacadePlugin.ts +0 -178
- package/resources/js/project/vendor/core-manager-js/src/uiManager/ui-base.css +0 -246
- package/resources/js/project/vendor/core-manager-js/src/videoManager/VideoManager.ts +0 -139
- package/resources/js/project/vendor/core-manager-js/tsconfig.json +0 -15
- package/resources/js/project/vendor/run.sh +0 -4
- package/resources/js/project/version/craft_feature_version.json +0 -42
- package/resources/js/project/version/project_feature_version.json +0 -11
- package/resources/js3d/context/.role/AGENTS_DESIGN.md +0 -9
- package/resources/js3d/context/knowledge/3D/PoseInterpolationKnowledge.md +0 -75
- package/resources/js3d/context/knowledge/CodingGuide/SceneEditableGuide.md +0 -42
- package/resources/js3d/context/knowledge/FrontendComponents.md +0 -19
- package/resources/js3d/context/knowledge/MobileAdaptation.md +0 -73
- package/resources/js3d/context/knowledge/MobileAdapted.md +0 -36
- package/resources/js3d/context/knowledge/Multiplayer/GameplaySystemKnowledge.md +0 -114
- package/resources/js3d/context/knowledge/Multiplayer/OverviewKnowledge.md +0 -117
- package/resources/js3d/context/knowledge/Multiplayer/StateSyncKnowledge.md +0 -430
- package/resources/js3d/context/knowledge/PlatformServices.md +0 -190
- package/resources/js3d/context/knowledge/ProjectDisplayConfig.md +0 -35
- package/resources/js3d/context/knowledge/SceneEditorCompat.md +0 -35
- package/resources/js3d/context/knowledge/StepByStep.md +0 -21
- package/resources/js3d/context/knowledge/Subsystems/Optional/MultiplayerManagerKnowledge.md +0 -242
- package/resources/js3d/context/knowledge/UiEditorCompat.md +0 -21
- package/resources/js3d/context/rules/MultiplayerCapability.md +0 -27
- package/resources/js3d/context/rules/MultiplayerRoomEntryUX.md +0 -63
- package/resources/js3d/context/rules/PlatformBoundaryModules.md +0 -44
- package/resources/js3d/context/rules/preview_ready.md +0 -8
- package/resources/js3d/context/skills/aigc-integration/assets/sprite-sheet-player.mjs +0 -70
- package/resources/js3d/context/skills/aigc-integration/callback.md +0 -77
- package/resources/js3d/context/skills/aigc-integration/knowledge/aigc/README.md +0 -23
- package/resources/js3d/context/skills/aigc-integration/knowledge/aigc/audio-aigc-knowledge.md +0 -38
- package/resources/js3d/context/skills/aigc-integration/knowledge/aigc/character2d-aigc-knowledge.md +0 -72
- package/resources/js3d/context/skills/aigc-integration/knowledge/aigc/staticmesh-aigc-knowledge.md +0 -33
- package/resources/js3d/context/skills/aigc-integration/knowledge/aigc/texture-prop-aigc-knowledge.md +0 -36
- package/resources/js3d/context/skills/aigc-integration/knowledge/aigc/texture-scene-aigc-knowledge.md +0 -37
- package/resources/js3d/context/skills/aigc-integration/knowledge/aigc/texture-ui-aigc-knowledge.md +0 -35
- package/resources/js3d/context/skills/asset-search/references/sprite-sheets.md +0 -58
- package/resources/js3d/context/skills/asset-search/scripts/asset_display.mjs +0 -62
- package/resources/js3d/context/skills/asset-search/scripts/config.json +0 -235
- package/resources/js3d/context/skills/asset-search/scripts/manifest_pipeline.mjs +0 -905
- package/resources/js3d/context/skills/asset-search/scripts/preflight.mjs +0 -79
- package/resources/js3d/context/skills/asset-search/scripts/provided_assets.mjs +0 -74
- package/resources/js3d/context/skills/asset-search/scripts/search.mjs +0 -637
- package/resources/js3d/context/skills/asset-search/scripts/sprite_source_materializer.mjs +0 -667
- package/resources/js3d/context/skills/asset-search/strategies/anim2d.md +0 -42
- package/resources/js3d/context/skills/asset-search/strategies/effect2d.md +0 -31
- package/resources/js3d/context/skills/asset-usage-audit/references/case-tidewater-zoo.md +0 -89
- package/resources/js3d/context/skills/asset-usage-audit/references/optimization-playbook.md +0 -143
- package/resources/js3d/context/skills/asset-usage-audit/references/usage-model.md +0 -90
- package/resources/js3d/context/skills/export-config/scripts/sync-scene-assets.mjs +0 -216
- package/resources/js3d/context/skills/export-config/scripts/translate-asset-titles.mjs +0 -161
- package/resources/js3d/context/skills/game-art-style/SKILL.md +0 -60
- package/resources/js3d/context/skills/game-art-style/assets/previews/cartoon.png +0 -0
- package/resources/js3d/context/skills/game-art-style/assets/previews/comic.png +0 -0
- package/resources/js3d/context/skills/game-art-style/assets/previews/cozy.png +0 -0
- package/resources/js3d/context/skills/game-art-style/assets/previews/cyber.png +0 -0
- package/resources/js3d/context/skills/game-art-style/assets/previews/horror.png +0 -0
- package/resources/js3d/context/skills/game-art-style/assets/previews/lowpoly.png +0 -0
- package/resources/js3d/context/skills/game-art-style/assets/previews/paper.png +0 -0
- package/resources/js3d/context/skills/game-art-style/assets/previews/voxel.png +0 -0
- package/resources/js3d/context/skills/game-art-style/references/art-parameters-lite.md +0 -38
- package/resources/js3d/context/skills/game-art-style/references/construction.md +0 -111
- package/resources/js3d/context/skills/game-art-style/references/materials-textures.md +0 -105
- package/resources/js3d/context/skills/game-art-style/references/sources.md +0 -25
- package/resources/js3d/context/skills/game-art-style/references/styles/cartoon.md +0 -175
- package/resources/js3d/context/skills/game-art-style/references/styles/comic.md +0 -168
- package/resources/js3d/context/skills/game-art-style/references/styles/cozy.md +0 -191
- package/resources/js3d/context/skills/game-art-style/references/styles/cyber.md +0 -165
- package/resources/js3d/context/skills/game-art-style/references/styles/horror.md +0 -173
- package/resources/js3d/context/skills/game-art-style/references/styles/lowpoly.md +0 -185
- package/resources/js3d/context/skills/game-art-style/references/styles/paper.md +0 -181
- package/resources/js3d/context/skills/game-art-style/references/styles/voxel.md +0 -189
- package/resources/js3d/context/skills/game-art-style/references/user-style-document.md +0 -88
- package/resources/js3d/context/skills/mobile-adaptation/SKILL.md +0 -301
- package/resources/js3d/context/skills/mobile-adaptation/assets/example/src/input/input-config.json +0 -104
- package/resources/js3d/context/skills/mobile-adaptation/assets/example/src/input/input-layer.ts +0 -933
- package/resources/js3d/context/skills/mobile-adaptation/assets/example/src/input/input-platform.ts +0 -92
- package/resources/js3d/context/skills/mobile-adaptation/assets/example/src/input/input-primitives.ts +0 -254
- package/resources/js3d/context/skills/mobile-adaptation/assets/example/src/input/look-pad.ts +0 -245
- package/resources/js3d/context/skills/mobile-adaptation/assets/example/src/ui/touch-controls.css +0 -257
- package/resources/js3d/context/skills/mobile-adaptation/references/input-config.md +0 -342
- package/resources/js3d/context/skills/mobile-adaptation/references/verification.md +0 -140
- package/resources/js3d/context/skills/mobile-adaptation/references/web-audio.md +0 -11
- package/resources/js3d/context/skills/mobile-compat-qa/SKILL.md +0 -53
- package/resources/js3d/context/skills/mobile-compat-qa/references/startup-diagnosis.md +0 -23
- package/resources/js3d/context/skills/mobile-compat-qa/references/web-form-input.md +0 -10
- package/resources/js3d/context/skills/mobile-compat-qa/references/web-lifecycle.md +0 -20
- package/resources/js3d/context/skills/mobile-compat-qa/references/web-performance.md +0 -19
- package/resources/js3d/context/skills/optimization-suggestions/SKILL.md +0 -74
- package/resources/js3d/context/skills/performance-audit/references/case-notes.md +0 -93
- package/resources/js3d/context/skills/performance-audit/references/rules.md +0 -183
- package/resources/js3d/context/skills/platform-services/SKILL.md +0 -101
- package/resources/js3d/context/skills/platform-services/assets/modules/MultiplayerManager.ts +0 -465
- package/resources/js3d/context/skills/platform-services/assets/modules/eventBus.ts +0 -57
- package/resources/js3d/context/skills/platform-services/assets/modules/leaderboard.d.mts +0 -39
- package/resources/js3d/context/skills/platform-services/assets/modules/leaderboard.mjs +0 -1
- package/resources/js3d/context/skills/platform-services/assets/modules/log.ts +0 -35
- package/resources/js3d/context/skills/platform-services/assets/modules/multiplayer/clockSync.ts +0 -61
- package/resources/js3d/context/skills/platform-services/assets/modules/multiplayer/dsClient.ts +0 -52
- package/resources/js3d/context/skills/platform-services/assets/modules/multiplayer/payloadCodec.ts +0 -30
- package/resources/js3d/context/skills/platform-services/assets/modules/multiplayer/roomHttp.ts +0 -89
- package/resources/js3d/context/skills/platform-services/assets/modules/multiplayer/types.ts +0 -47
- package/resources/js3d/context/skills/platform-services/assets/modules/save.d.mts +0 -49
- package/resources/js3d/context/skills/platform-services/assets/modules/save.mjs +0 -1
- package/resources/js3d/context/skills/platform-services/assets/scaffold/ds/main.mjs +0 -7
- package/resources/js3d/context/skills/platform-services/assets/scaffold/ds/rooms/SyncRoom.mjs +0 -264
- package/resources/js3d/context/skills/platform-services/assets/scaffold/ds/rooms/syncSchema.mjs +0 -39
- package/resources/js3d/context/skills/platform-services/references/SERVER_GUIDE.md +0 -139
- package/resources/js3d/context/skills/platform-services/references/api_reference.md +0 -18
- package/resources/js3d/context/skills/platform-services/references/leaderboard_playbook.md +0 -96
- package/resources/js3d/context/skills/platform-services/scripts/install.mjs +0 -148
- package/resources/js3d/context/skills/resolution-adaptation/SKILL.md +0 -46
- package/resources/js3d/context/skills/resolution-adaptation/assets/example/main.ts +0 -129
- package/resources/js3d/context/skills/resolution-adaptation/assets/example/ui-tokens.css +0 -188
- package/resources/js3d/context/skills/resolution-adaptation/references/audit.md +0 -31
- package/resources/js3d/context/skills/resolution-adaptation/references/device-safe-area.md +0 -40
- package/resources/js3d/context/skills/resolution-adaptation/references/game-ui-occlusion.md +0 -18
- package/resources/js3d/context/skills/resolution-adaptation/references/layout-rules.md +0 -15
- package/resources/js3d/context/skills/resolution-adaptation/references/troubleshooting.md +0 -34
- package/resources/js3d/context/skills/resolution-adaptation/references/viewport-api.md +0 -38
- package/resources/js3d/context/skills/resolution-adaptation/scripts/aspect_audit.mjs +0 -448
- package/resources/js3d/context/skills/scene-editor-compat/SKILL.md +0 -599
- package/resources/js3d/context/skills/scene-editor-compat/references/bundle-contract.md +0 -141
- package/resources/js3d/context/skills/scene-editor-compat/references/editor-integration.md +0 -92
- package/resources/js3d/context/skills/scene-editor-compat/references/scene-data-format.md +0 -125
- package/resources/js3d/context/skills/scene-editor-compat/references/slots-rules.md +0 -113
- package/resources/js3d/context/skills/scene-editor-compat/scripts/scene-editor.mjs +0 -1187
- package/resources/js3d/context/skills/threejs-game-quality/SKILL.md +0 -53
- package/resources/js3d/context/skills/threejs-game-quality/agents/openai.yaml +0 -4
- package/resources/js3d/context/skills/threejs-game-quality/references/01-build.md +0 -94
- package/resources/js3d/context/skills/threejs-game-quality/references/02-avoid.md +0 -50
- package/resources/js3d/context/skills/threejs-game-quality/references/03-detect.md +0 -105
- package/resources/js3d/context/skills/threejs-game-quality/references/camera-by-genre.md +0 -147
- package/resources/js3d/context/skills/threejs-game-quality/references/camera-distance.md +0 -79
- package/resources/js3d/context/skills/threejs-game-quality/references/camera-sources.md +0 -56
- package/resources/js3d/context/skills/threejs-game-quality/references/character-motion-face.md +0 -51
- package/resources/js3d/context/skills/threejs-game-quality/references/parameter-contract.md +0 -55
- package/resources/js3d/context/skills/threejs-game-quality/references/refine-existing.md +0 -78
- package/resources/js3d/context/skills/threejs-game-quality/references/rendering-stability.md +0 -84
- package/resources/js3d/context/skills/threejs-game-quality/references/runtime-tools.md +0 -120
- package/resources/js3d/context/skills/threejs-game-quality/scripts/package.json +0 -4
- package/resources/js3d/context/skills/threejs-game-quality/scripts/runtime-audit.js +0 -238
- package/resources/js3d/context/skills/ui-editor-compat/SKILL.md +0 -59
- package/resources/js3d/context/skills/ui-editor-compat/assets/example/hud/WidgetLayout_Hud.ts +0 -35
- package/resources/js3d/context/skills/ui-editor-compat/assets/example/hud/WidgetLogic_Hud.ts +0 -61
- package/resources/js3d/context/skills/ui-editor-compat/assets/example/hud/hud.css +0 -60
- package/resources/js3d/context/skills/ui-editor-compat/assets/runtime/dom-ui.d.mts +0 -45
- package/resources/js3d/context/skills/ui-editor-compat/assets/runtime/dom-ui.mjs +0 -265
- package/resources/js3d/context/skills/ui-editor-compat/assets/runtime/release.json +0 -7
- package/resources/js3d/context/skills/ui-editor-compat/references/contract.md +0 -110
- package/resources/js3d/context/skills/ui-editor-compat/scripts/editor-contract.mjs +0 -327
- package/resources/js3d/context/skills/ui-editor-compat/scripts/project-files.mjs +0 -80
- package/resources/js3d/context/skills/ui-editor-compat/scripts/ui-editor.mjs +0 -84
- package/resources/js3d/context/skills/version-update/SKILL.md +0 -191
- package/resources/js3d/context/skills/version-update/scripts/check_runtime_refs.mjs +0 -129
- package/resources/js3d/context/skills/version-update/scripts/feature_snapshot.mjs +0 -159
- package/resources/js3d/context/skills/version-update/scripts/update_feature_version.mjs +0 -157
- package/resources/js3d/context/skills/version-update/upgrade_diffs/.gitkeep +0 -0
- package/resources/js3d/context/version/version.json +0 -1
- package/resources/js3d/project/runtime/lightgame/1.0.0/platform/leaderboard.d.mts +0 -39
- package/resources/js3d/project/runtime/lightgame/1.0.0/platform/leaderboard.mjs +0 -1
- package/resources/js3d/project/runtime/lightgame/1.0.0/platform/platform-service.d.mts +0 -25
- package/resources/js3d/project/runtime/lightgame/1.0.0/platform/platform-service.mjs +0 -1
- package/resources/js3d/project/runtime/lightgame/1.0.0/platform/platform.mjs +0 -30
- package/resources/js3d/project/runtime/lightgame/1.0.0/platform/save.d.mts +0 -49
- package/resources/js3d/project/runtime/lightgame/1.0.0/platform/save.mjs +0 -1
- package/resources/js3d/project/runtime/lightgame/1.0.0/release.json +0 -39
- package/resources/js3d/project/runtime/lightgame/1.0.0/tooling/cli.mjs +0 -2
- package/resources/js3d/project/runtime/lightgame/1.0.0/tooling/project.d.mts +0 -8
- package/resources/js3d/project/runtime/lightgame/1.0.0/tooling/project.mjs +0 -2
- package/resources/js3d/project/runtime/lightgame/1.0.0/tooling/vite.d.mts +0 -3
- package/resources/js3d/project/runtime/lightgame/1.0.0/tooling/vite.mjs +0 -7
- package/resources/js3d/project/runtime/lightgame/1.0.0/tools/audio.d.mts +0 -20
- package/resources/js3d/project/runtime/lightgame/1.0.0/tools/audio.mjs +0 -1
- package/resources/js3d/project/runtime/lightgame/1.0.0/tools/canvas.d.mts +0 -21
- package/resources/js3d/project/runtime/lightgame/1.0.0/tools/canvas.mjs +0 -1
- package/resources/js3d/project/runtime/lightgame/1.0.0/tools/input.d.mts +0 -17
- package/resources/js3d/project/runtime/lightgame/1.0.0/tools/input.mjs +0 -1
- package/resources/js3d/project/runtime/lightgame/1.0.0/tools/three.d.mts +0 -40
- package/resources/js3d/project/runtime/lightgame/1.0.0/tools/three.mjs +0 -1
- package/resources/js3d/project/runtime/lightgame/1.0.0/tools/ui.d.mts +0 -10
- package/resources/js3d/project/runtime/lightgame/1.0.0/tools/ui.mjs +0 -1
- package/resources/js3d/project/runtime/lightgame/1.0.0/tools/video.d.mts +0 -8
- package/resources/js3d/project/runtime/lightgame/1.0.0/tools/video.mjs +0 -1
- package/resources/js3d/project/scripts/refresh-runtime.mjs +0 -50
- package/resources/js3d/project/vendor/core-manager-three/package.json +0 -12
- package/resources/js3d/project/vendor/core-manager-three/src/index.ts +0 -2
- package/resources/js3d/project/vendor/run.sh +0 -4
- package/resources/js3d/project/version/craft_feature_version.json +0 -42
- package/resources/js3d/project/version/project_feature_version.json +0 -11
- package/vendor/agent-cli/dist/runtime-tools/registry.json +0 -6
- package/vendor/agent-cli/dist/runtime-tools/tool-bundle-types.d.cts +0 -15
- package/vendor/agent-cli/dist/runtime-tools/tool-bundle.cjs +0 -129
- package/vendor/agent-cli/dist/runtime-tools/ue/blender-cook-assets.cjs +0 -296
- package/vendor/agent-cli/dist/runtime-tools/ue/context-adapter.cjs +0 -48
- package/vendor/agent-cli/dist/runtime-tools/ue/scene-process-lock.cjs +0 -110
- package/vendor/agent-cli/dist/runtime-tools/ue/tool-manifest.json +0 -22
- package/vendor/agent-cli/dist/runtime-tools/ue/ue-asset-references.cjs +0 -305
- package/vendor/agent-cli/dist/src/artifacts/context-finalize.d.ts +0 -3
- package/vendor/agent-cli/dist/src/artifacts/context-finalize.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/context-finalize.js +0 -54
- package/vendor/agent-cli/dist/src/artifacts/context-finalize.js.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/external-game-archive.d.ts +0 -19
- package/vendor/agent-cli/dist/src/artifacts/external-game-archive.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/external-game-archive.js +0 -107
- package/vendor/agent-cli/dist/src/artifacts/external-game-archive.js.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/external-game-upload.d.ts +0 -44
- package/vendor/agent-cli/dist/src/artifacts/external-game-upload.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/external-game-upload.js +0 -106
- package/vendor/agent-cli/dist/src/artifacts/external-game-upload.js.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/native-source.d.ts +0 -3
- package/vendor/agent-cli/dist/src/artifacts/native-source.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/native-source.js +0 -13
- package/vendor/agent-cli/dist/src/artifacts/native-source.js.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/preinstalled-dependencies.d.ts +0 -13
- package/vendor/agent-cli/dist/src/artifacts/preinstalled-dependencies.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/preinstalled-dependencies.js +0 -364
- package/vendor/agent-cli/dist/src/artifacts/preinstalled-dependencies.js.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/prepare.d.ts +0 -61
- package/vendor/agent-cli/dist/src/artifacts/prepare.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/prepare.js +0 -211
- package/vendor/agent-cli/dist/src/artifacts/prepare.js.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/process-artifacts.d.ts +0 -39
- package/vendor/agent-cli/dist/src/artifacts/process-artifacts.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/process-artifacts.js +0 -173
- package/vendor/agent-cli/dist/src/artifacts/process-artifacts.js.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/restore-permissions.d.ts +0 -27
- package/vendor/agent-cli/dist/src/artifacts/restore-permissions.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/restore-permissions.js +0 -112
- package/vendor/agent-cli/dist/src/artifacts/restore-permissions.js.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/restore.d.ts +0 -37
- package/vendor/agent-cli/dist/src/artifacts/restore.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/restore.js +0 -465
- package/vendor/agent-cli/dist/src/artifacts/restore.js.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/scene-asset-delivery.d.ts +0 -7
- package/vendor/agent-cli/dist/src/artifacts/scene-asset-delivery.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/scene-asset-delivery.js +0 -145
- package/vendor/agent-cli/dist/src/artifacts/scene-asset-delivery.js.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/static.d.ts +0 -19
- package/vendor/agent-cli/dist/src/artifacts/static.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/artifacts/static.js +0 -224
- package/vendor/agent-cli/dist/src/artifacts/static.js.map +0 -1
- package/vendor/agent-cli/dist/src/cli/commands/process.d.ts +0 -4
- package/vendor/agent-cli/dist/src/cli/commands/process.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/cli/commands/process.js +0 -24
- package/vendor/agent-cli/dist/src/cli/commands/process.js.map +0 -1
- package/vendor/agent-cli/dist/src/cli/commands/run-controls.d.ts +0 -23
- package/vendor/agent-cli/dist/src/cli/commands/run-controls.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/cli/commands/run-controls.js +0 -62
- package/vendor/agent-cli/dist/src/cli/commands/run-controls.js.map +0 -1
- package/vendor/agent-cli/dist/src/cli/commands/run-mock.d.ts +0 -9
- package/vendor/agent-cli/dist/src/cli/commands/run-mock.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/cli/commands/run-mock.js +0 -15
- package/vendor/agent-cli/dist/src/cli/commands/run-mock.js.map +0 -1
- package/vendor/agent-cli/dist/src/cli/commands/run.d.ts +0 -3
- package/vendor/agent-cli/dist/src/cli/commands/run.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/cli/commands/run.js +0 -284
- package/vendor/agent-cli/dist/src/cli/commands/run.js.map +0 -1
- package/vendor/agent-cli/dist/src/cli/commands/setup.d.ts +0 -11
- package/vendor/agent-cli/dist/src/cli/commands/setup.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/cli/commands/setup.js +0 -161
- package/vendor/agent-cli/dist/src/cli/commands/setup.js.map +0 -1
- package/vendor/agent-cli/dist/src/cli/options.d.ts +0 -83
- package/vendor/agent-cli/dist/src/cli/options.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/cli/options.js +0 -213
- package/vendor/agent-cli/dist/src/cli/options.js.map +0 -1
- package/vendor/agent-cli/dist/src/cli/process-protocol.d.ts +0 -5
- package/vendor/agent-cli/dist/src/cli/process-protocol.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/cli/process-protocol.js +0 -279
- package/vendor/agent-cli/dist/src/cli/process-protocol.js.map +0 -1
- package/vendor/agent-cli/dist/src/cli/registry.d.ts +0 -55
- package/vendor/agent-cli/dist/src/cli/registry.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/cli/registry.js +0 -99
- package/vendor/agent-cli/dist/src/cli/registry.js.map +0 -1
- package/vendor/agent-cli/dist/src/cli/render/jsonl-sink.d.ts +0 -44
- package/vendor/agent-cli/dist/src/cli/render/jsonl-sink.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/cli/render/jsonl-sink.js +0 -83
- package/vendor/agent-cli/dist/src/cli/render/jsonl-sink.js.map +0 -1
- package/vendor/agent-cli/dist/src/cli/render/text-sink.d.ts +0 -28
- package/vendor/agent-cli/dist/src/cli/render/text-sink.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/cli/render/text-sink.js +0 -52
- package/vendor/agent-cli/dist/src/cli/render/text-sink.js.map +0 -1
- package/vendor/agent-cli/dist/src/cli.d.ts +0 -9
- package/vendor/agent-cli/dist/src/cli.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/cli.js +0 -54
- package/vendor/agent-cli/dist/src/cli.js.map +0 -1
- package/vendor/agent-cli/dist/src/component/browser-queue.d.ts +0 -55
- package/vendor/agent-cli/dist/src/component/browser-queue.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/component/browser-queue.js +0 -63
- package/vendor/agent-cli/dist/src/component/browser-queue.js.map +0 -1
- package/vendor/agent-cli/dist/src/component/execution.d.ts +0 -28
- package/vendor/agent-cli/dist/src/component/execution.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/component/execution.js +0 -143
- package/vendor/agent-cli/dist/src/component/execution.js.map +0 -1
- package/vendor/agent-cli/dist/src/component/isolated-launcher.d.ts +0 -2
- package/vendor/agent-cli/dist/src/component/isolated-launcher.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/component/isolated-launcher.js +0 -76
- package/vendor/agent-cli/dist/src/component/isolated-launcher.js.map +0 -1
- package/vendor/agent-cli/dist/src/component/isolated-preload.d.ts +0 -2
- package/vendor/agent-cli/dist/src/component/isolated-preload.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/component/isolated-preload.js +0 -27
- package/vendor/agent-cli/dist/src/component/isolated-preload.js.map +0 -1
- package/vendor/agent-cli/dist/src/component/platform-access/server.d.ts +0 -19
- package/vendor/agent-cli/dist/src/component/platform-access/server.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/component/platform-access/server.js +0 -206
- package/vendor/agent-cli/dist/src/component/platform-access/server.js.map +0 -1
- package/vendor/agent-cli/dist/src/component/preparation-diagnostics.d.ts +0 -31
- package/vendor/agent-cli/dist/src/component/preparation-diagnostics.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/component/preparation-diagnostics.js +0 -62
- package/vendor/agent-cli/dist/src/component/preparation-diagnostics.js.map +0 -1
- package/vendor/agent-cli/dist/src/component/preparation.d.ts +0 -10
- package/vendor/agent-cli/dist/src/component/preparation.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/component/preparation.js +0 -35
- package/vendor/agent-cli/dist/src/component/preparation.js.map +0 -1
- package/vendor/agent-cli/dist/src/component/process-diagnostics.d.ts +0 -25
- package/vendor/agent-cli/dist/src/component/process-diagnostics.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/component/process-diagnostics.js +0 -137
- package/vendor/agent-cli/dist/src/component/process-diagnostics.js.map +0 -1
- package/vendor/agent-cli/dist/src/component/process-isolation.d.ts +0 -10
- package/vendor/agent-cli/dist/src/component/process-isolation.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/component/process-isolation.js +0 -59
- package/vendor/agent-cli/dist/src/component/process-isolation.js.map +0 -1
- package/vendor/agent-cli/dist/src/component/proxied-fetch.d.ts +0 -2
- package/vendor/agent-cli/dist/src/component/proxied-fetch.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/component/proxied-fetch.js +0 -46
- package/vendor/agent-cli/dist/src/component/proxied-fetch.js.map +0 -1
- package/vendor/agent-cli/dist/src/component/public-egress.d.ts +0 -17
- package/vendor/agent-cli/dist/src/component/public-egress.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/component/public-egress.js +0 -246
- package/vendor/agent-cli/dist/src/component/public-egress.js.map +0 -1
- package/vendor/agent-cli/dist/src/component/runtime-tools.d.ts +0 -15
- package/vendor/agent-cli/dist/src/component/runtime-tools.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/component/runtime-tools.js +0 -37
- package/vendor/agent-cli/dist/src/component/runtime-tools.js.map +0 -1
- package/vendor/agent-cli/dist/src/component/runtime.d.ts +0 -8
- package/vendor/agent-cli/dist/src/component/runtime.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/component/runtime.js +0 -95
- package/vendor/agent-cli/dist/src/component/runtime.js.map +0 -1
- package/vendor/agent-cli/dist/src/config/config-store.d.ts +0 -50
- package/vendor/agent-cli/dist/src/config/config-store.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/config/config-store.js +0 -117
- package/vendor/agent-cli/dist/src/config/config-store.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/cache-lease.d.ts +0 -17
- package/vendor/agent-cli/dist/src/context/cache-lease.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/cache-lease.js +0 -133
- package/vendor/agent-cli/dist/src/context/cache-lease.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/cache-prune-diagnostics.d.ts +0 -9
- package/vendor/agent-cli/dist/src/context/cache-prune-diagnostics.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/cache-prune-diagnostics.js +0 -51
- package/vendor/agent-cli/dist/src/context/cache-prune-diagnostics.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/cache-publication-lock.d.ts +0 -3
- package/vendor/agent-cli/dist/src/context/cache-publication-lock.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/cache-publication-lock.js +0 -68
- package/vendor/agent-cli/dist/src/context/cache-publication-lock.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/cache-publication.d.ts +0 -4
- package/vendor/agent-cli/dist/src/context/cache-publication.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/cache-publication.js +0 -58
- package/vendor/agent-cli/dist/src/context/cache-publication.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/client-context-view.d.ts +0 -12
- package/vendor/agent-cli/dist/src/context/client-context-view.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/client-context-view.js +0 -100
- package/vendor/agent-cli/dist/src/context/client-context-view.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/context-budget.d.ts +0 -3
- package/vendor/agent-cli/dist/src/context/context-budget.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/context-budget.js +0 -10
- package/vendor/agent-cli/dist/src/context/context-budget.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/context-cache.d.ts +0 -108
- package/vendor/agent-cli/dist/src/context/context-cache.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/context-cache.js +0 -360
- package/vendor/agent-cli/dist/src/context/context-cache.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/context-project.d.ts +0 -67
- package/vendor/agent-cli/dist/src/context/context-project.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/context-project.js +0 -254
- package/vendor/agent-cli/dist/src/context/context-project.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/context-resource.d.ts +0 -4
- package/vendor/agent-cli/dist/src/context/context-resource.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/context-resource.js +0 -11
- package/vendor/agent-cli/dist/src/context/context-resource.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/context-scoped-source.d.ts +0 -13
- package/vendor/agent-cli/dist/src/context/context-scoped-source.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/context-scoped-source.js +0 -78
- package/vendor/agent-cli/dist/src/context/context-scoped-source.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/context-snapshot-cache.d.ts +0 -23
- package/vendor/agent-cli/dist/src/context/context-snapshot-cache.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/context-snapshot-cache.js +0 -200
- package/vendor/agent-cli/dist/src/context/context-snapshot-cache.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/local-skills.d.ts +0 -6
- package/vendor/agent-cli/dist/src/context/local-skills.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/local-skills.js +0 -174
- package/vendor/agent-cli/dist/src/context/local-skills.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/member-context.d.ts +0 -20
- package/vendor/agent-cli/dist/src/context/member-context.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/member-context.js +0 -113
- package/vendor/agent-cli/dist/src/context/member-context.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/member-documents.d.ts +0 -3
- package/vendor/agent-cli/dist/src/context/member-documents.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/member-documents.js +0 -38
- package/vendor/agent-cli/dist/src/context/member-documents.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/member-profile-header.d.ts +0 -3
- package/vendor/agent-cli/dist/src/context/member-profile-header.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/member-profile-header.js +0 -62
- package/vendor/agent-cli/dist/src/context/member-profile-header.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/member-profile.d.ts +0 -43
- package/vendor/agent-cli/dist/src/context/member-profile.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/member-profile.js +0 -91
- package/vendor/agent-cli/dist/src/context/member-profile.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/member-selection.d.ts +0 -7
- package/vendor/agent-cli/dist/src/context/member-selection.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/member-selection.js +0 -58
- package/vendor/agent-cli/dist/src/context/member-selection.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/script-dependencies.d.ts +0 -14
- package/vendor/agent-cli/dist/src/context/script-dependencies.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/script-dependencies.js +0 -40
- package/vendor/agent-cli/dist/src/context/script-dependencies.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/shared-cache-build.d.ts +0 -3
- package/vendor/agent-cli/dist/src/context/shared-cache-build.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/shared-cache-build.js +0 -56
- package/vendor/agent-cli/dist/src/context/shared-cache-build.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/team-definition.d.ts +0 -39
- package/vendor/agent-cli/dist/src/context/team-definition.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/team-definition.js +0 -78
- package/vendor/agent-cli/dist/src/context/team-definition.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/team-knowledge.d.ts +0 -7
- package/vendor/agent-cli/dist/src/context/team-knowledge.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/team-knowledge.js +0 -46
- package/vendor/agent-cli/dist/src/context/team-knowledge.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/template-cache.d.ts +0 -31
- package/vendor/agent-cli/dist/src/context/template-cache.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/template-cache.js +0 -100
- package/vendor/agent-cli/dist/src/context/template-cache.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/template-refresh.d.ts +0 -6
- package/vendor/agent-cli/dist/src/context/template-refresh.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/template-refresh.js +0 -45
- package/vendor/agent-cli/dist/src/context/template-refresh.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/template-seed.d.ts +0 -45
- package/vendor/agent-cli/dist/src/context/template-seed.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/template-seed.js +0 -169
- package/vendor/agent-cli/dist/src/context/template-seed.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/template-sync.d.ts +0 -11
- package/vendor/agent-cli/dist/src/context/template-sync.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/template-sync.js +0 -167
- package/vendor/agent-cli/dist/src/context/template-sync.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/user-skill-bundle.d.ts +0 -19
- package/vendor/agent-cli/dist/src/context/user-skill-bundle.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/user-skill-bundle.js +0 -292
- package/vendor/agent-cli/dist/src/context/user-skill-bundle.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/user-skill-context.d.ts +0 -15
- package/vendor/agent-cli/dist/src/context/user-skill-context.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/user-skill-context.js +0 -217
- package/vendor/agent-cli/dist/src/context/user-skill-context.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/user-skill-install.d.ts +0 -54
- package/vendor/agent-cli/dist/src/context/user-skill-install.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/user-skill-install.js +0 -184
- package/vendor/agent-cli/dist/src/context/user-skill-install.js.map +0 -1
- package/vendor/agent-cli/dist/src/context/zip-extract.d.ts +0 -14
- package/vendor/agent-cli/dist/src/context/zip-extract.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/context/zip-extract.js +0 -130
- package/vendor/agent-cli/dist/src/context/zip-extract.js.map +0 -1
- package/vendor/agent-cli/dist/src/index.d.ts +0 -62
- package/vendor/agent-cli/dist/src/index.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/index.js +0 -88
- package/vendor/agent-cli/dist/src/index.js.map +0 -1
- package/vendor/agent-cli/dist/src/lifecycle/engine-hooks.d.ts +0 -68
- package/vendor/agent-cli/dist/src/lifecycle/engine-hooks.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/lifecycle/engine-hooks.js +0 -244
- package/vendor/agent-cli/dist/src/lifecycle/engine-hooks.js.map +0 -1
- package/vendor/agent-cli/dist/src/lifecycle/hook-command.d.ts +0 -40
- package/vendor/agent-cli/dist/src/lifecycle/hook-command.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/lifecycle/hook-command.js +0 -87
- package/vendor/agent-cli/dist/src/lifecycle/hook-command.js.map +0 -1
- package/vendor/agent-cli/dist/src/lifecycle/registry.d.ts +0 -134
- package/vendor/agent-cli/dist/src/lifecycle/registry.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/lifecycle/registry.js +0 -152
- package/vendor/agent-cli/dist/src/lifecycle/registry.js.map +0 -1
- package/vendor/agent-cli/dist/src/lifecycle/workspace-change.d.ts +0 -40
- package/vendor/agent-cli/dist/src/lifecycle/workspace-change.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/lifecycle/workspace-change.js +0 -149
- package/vendor/agent-cli/dist/src/lifecycle/workspace-change.js.map +0 -1
- package/vendor/agent-cli/dist/src/mcp/client.d.ts +0 -12
- package/vendor/agent-cli/dist/src/mcp/client.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/mcp/client.js +0 -95
- package/vendor/agent-cli/dist/src/mcp/client.js.map +0 -1
- package/vendor/agent-cli/dist/src/mcp/connection.d.ts +0 -14
- package/vendor/agent-cli/dist/src/mcp/connection.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/mcp/connection.js +0 -115
- package/vendor/agent-cli/dist/src/mcp/connection.js.map +0 -1
- package/vendor/agent-cli/dist/src/mcp/execute.d.ts +0 -5
- package/vendor/agent-cli/dist/src/mcp/execute.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/mcp/execute.js +0 -26
- package/vendor/agent-cli/dist/src/mcp/execute.js.map +0 -1
- package/vendor/agent-cli/dist/src/mcp/instance-lock.d.ts +0 -11
- package/vendor/agent-cli/dist/src/mcp/instance-lock.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/mcp/instance-lock.js +0 -51
- package/vendor/agent-cli/dist/src/mcp/instance-lock.js.map +0 -1
- package/vendor/agent-cli/dist/src/mcp/types.d.ts +0 -27
- package/vendor/agent-cli/dist/src/mcp/types.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/mcp/types.js +0 -2
- package/vendor/agent-cli/dist/src/mcp/types.js.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/input.d.ts +0 -21
- package/vendor/agent-cli/dist/src/protocol/input.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/input.js +0 -95
- package/vendor/agent-cli/dist/src/protocol/input.js.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/channel.d.ts +0 -58
- package/vendor/agent-cli/dist/src/protocol/link/channel.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/channel.js +0 -337
- package/vendor/agent-cli/dist/src/protocol/link/channel.js.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/codec-json.d.ts +0 -13
- package/vendor/agent-cli/dist/src/protocol/link/codec-json.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/codec-json.js +0 -27
- package/vendor/agent-cli/dist/src/protocol/link/codec-json.js.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/envelope.d.ts +0 -57
- package/vendor/agent-cli/dist/src/protocol/link/envelope.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/envelope.js +0 -93
- package/vendor/agent-cli/dist/src/protocol/link/envelope.js.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/liveness.d.ts +0 -28
- package/vendor/agent-cli/dist/src/protocol/link/liveness.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/liveness.js +0 -86
- package/vendor/agent-cli/dist/src/protocol/link/liveness.js.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/middleware.d.ts +0 -14
- package/vendor/agent-cli/dist/src/protocol/link/middleware.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/middleware.js +0 -40
- package/vendor/agent-cli/dist/src/protocol/link/middleware.js.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/rpc.d.ts +0 -31
- package/vendor/agent-cli/dist/src/protocol/link/rpc.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/rpc.js +0 -90
- package/vendor/agent-cli/dist/src/protocol/link/rpc.js.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/transport-ws.d.ts +0 -32
- package/vendor/agent-cli/dist/src/protocol/link/transport-ws.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/link/transport-ws.js +0 -106
- package/vendor/agent-cli/dist/src/protocol/link/transport-ws.js.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/messages/errors.gen.d.ts +0 -533
- package/vendor/agent-cli/dist/src/protocol/messages/errors.gen.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/messages/errors.gen.js +0 -137
- package/vendor/agent-cli/dist/src/protocol/messages/errors.gen.js.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/messages/messages.gen.d.ts +0 -420
- package/vendor/agent-cli/dist/src/protocol/messages/messages.gen.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/protocol/messages/messages.gen.js +0 -116
- package/vendor/agent-cli/dist/src/protocol/messages/messages.gen.js.map +0 -1
- package/vendor/agent-cli/dist/src/security/binary-read-receipts.d.ts +0 -9
- package/vendor/agent-cli/dist/src/security/binary-read-receipts.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/security/binary-read-receipts.js +0 -58
- package/vendor/agent-cli/dist/src/security/binary-read-receipts.js.map +0 -1
- package/vendor/agent-cli/dist/src/security/command-parse.d.ts +0 -21
- package/vendor/agent-cli/dist/src/security/command-parse.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/security/command-parse.js +0 -395
- package/vendor/agent-cli/dist/src/security/command-parse.js.map +0 -1
- package/vendor/agent-cli/dist/src/security/command-translate.d.ts +0 -30
- package/vendor/agent-cli/dist/src/security/command-translate.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/security/command-translate.js +0 -165
- package/vendor/agent-cli/dist/src/security/command-translate.js.map +0 -1
- package/vendor/agent-cli/dist/src/security/context-write-policy.d.ts +0 -18
- package/vendor/agent-cli/dist/src/security/context-write-policy.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/security/context-write-policy.js +0 -121
- package/vendor/agent-cli/dist/src/security/context-write-policy.js.map +0 -1
- package/vendor/agent-cli/dist/src/security/guard.d.ts +0 -45
- package/vendor/agent-cli/dist/src/security/guard.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/security/guard.js +0 -166
- package/vendor/agent-cli/dist/src/security/guard.js.map +0 -1
- package/vendor/agent-cli/dist/src/security/mount-table.d.ts +0 -56
- package/vendor/agent-cli/dist/src/security/mount-table.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/security/mount-table.js +0 -251
- package/vendor/agent-cli/dist/src/security/mount-table.js.map +0 -1
- package/vendor/agent-cli/dist/src/security/sandbox-path.d.ts +0 -23
- package/vendor/agent-cli/dist/src/security/sandbox-path.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/security/sandbox-path.js +0 -110
- package/vendor/agent-cli/dist/src/security/sandbox-path.js.map +0 -1
- package/vendor/agent-cli/dist/src/security/tool-run-owner.d.ts +0 -5
- package/vendor/agent-cli/dist/src/security/tool-run-owner.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/security/tool-run-owner.js +0 -16
- package/vendor/agent-cli/dist/src/security/tool-run-owner.js.map +0 -1
- package/vendor/agent-cli/dist/src/security/tool-scope.d.ts +0 -19
- package/vendor/agent-cli/dist/src/security/tool-scope.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/security/tool-scope.js +0 -122
- package/vendor/agent-cli/dist/src/security/tool-scope.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/client.d.ts +0 -136
- package/vendor/agent-cli/dist/src/session/client.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/client.js +0 -400
- package/vendor/agent-cli/dist/src/session/client.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/custom-context.d.ts +0 -6
- package/vendor/agent-cli/dist/src/session/custom-context.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/custom-context.js +0 -106
- package/vendor/agent-cli/dist/src/session/custom-context.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/engine-decide.d.ts +0 -38
- package/vendor/agent-cli/dist/src/session/engine-decide.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/engine-decide.js +0 -87
- package/vendor/agent-cli/dist/src/session/engine-decide.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/execution-recovery.d.ts +0 -9
- package/vendor/agent-cli/dist/src/session/execution-recovery.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/execution-recovery.js +0 -49
- package/vendor/agent-cli/dist/src/session/execution-recovery.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/execution-settlement.d.ts +0 -4
- package/vendor/agent-cli/dist/src/session/execution-settlement.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/execution-settlement.js +0 -15
- package/vendor/agent-cli/dist/src/session/execution-settlement.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/expert-definition.d.ts +0 -4
- package/vendor/agent-cli/dist/src/session/expert-definition.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/expert-definition.js +0 -20
- package/vendor/agent-cli/dist/src/session/expert-definition.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/link-config.d.ts +0 -13
- package/vendor/agent-cli/dist/src/session/link-config.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/link-config.js +0 -29
- package/vendor/agent-cli/dist/src/session/link-config.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/link-outcome.d.ts +0 -30
- package/vendor/agent-cli/dist/src/session/link-outcome.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/link-outcome.js +0 -67
- package/vendor/agent-cli/dist/src/session/link-outcome.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/link-session.d.ts +0 -77
- package/vendor/agent-cli/dist/src/session/link-session.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/link-session.js +0 -432
- package/vendor/agent-cli/dist/src/session/link-session.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/local-execution.d.ts +0 -28
- package/vendor/agent-cli/dist/src/session/local-execution.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/local-execution.js +0 -119
- package/vendor/agent-cli/dist/src/session/local-execution.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/member-tools.d.ts +0 -22
- package/vendor/agent-cli/dist/src/session/member-tools.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/member-tools.js +0 -72
- package/vendor/agent-cli/dist/src/session/member-tools.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-artifact-publisher.d.ts +0 -7
- package/vendor/agent-cli/dist/src/session/process-artifact-publisher.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-artifact-publisher.js +0 -30
- package/vendor/agent-cli/dist/src/session/process-artifact-publisher.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-environment.d.ts +0 -3
- package/vendor/agent-cli/dist/src/session/process-environment.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-environment.js +0 -33
- package/vendor/agent-cli/dist/src/session/process-environment.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-lifecycle.d.ts +0 -5
- package/vendor/agent-cli/dist/src/session/process-lifecycle.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-lifecycle.js +0 -18
- package/vendor/agent-cli/dist/src/session/process-lifecycle.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-observability.d.ts +0 -4
- package/vendor/agent-cli/dist/src/session/process-observability.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-observability.js +0 -14
- package/vendor/agent-cli/dist/src/session/process-observability.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-request.d.ts +0 -37
- package/vendor/agent-cli/dist/src/session/process-request.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-request.js +0 -473
- package/vendor/agent-cli/dist/src/session/process-request.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-restore.d.ts +0 -4
- package/vendor/agent-cli/dist/src/session/process-restore.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-restore.js +0 -21
- package/vendor/agent-cli/dist/src/session/process-restore.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-summary-output.d.ts +0 -15
- package/vendor/agent-cli/dist/src/session/process-summary-output.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-summary-output.js +0 -46
- package/vendor/agent-cli/dist/src/session/process-summary-output.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-workspace.d.ts +0 -3
- package/vendor/agent-cli/dist/src/session/process-workspace.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/process-workspace.js +0 -21
- package/vendor/agent-cli/dist/src/session/process-workspace.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/reference-tools.d.ts +0 -8
- package/vendor/agent-cli/dist/src/session/reference-tools.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/reference-tools.js +0 -35
- package/vendor/agent-cli/dist/src/session/reference-tools.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/run-events.d.ts +0 -81
- package/vendor/agent-cli/dist/src/session/run-events.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/run-events.js +0 -160
- package/vendor/agent-cli/dist/src/session/run-events.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/run-setup.d.ts +0 -78
- package/vendor/agent-cli/dist/src/session/run-setup.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/run-setup.js +0 -294
- package/vendor/agent-cli/dist/src/session/run-setup.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/run-start-body.d.ts +0 -47
- package/vendor/agent-cli/dist/src/session/run-start-body.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/run-start-body.js +0 -77
- package/vendor/agent-cli/dist/src/session/run-start-body.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/team-persistence.d.ts +0 -17
- package/vendor/agent-cli/dist/src/session/team-persistence.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/team-persistence.js +0 -75
- package/vendor/agent-cli/dist/src/session/team-persistence.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/tool-scheduler.d.ts +0 -37
- package/vendor/agent-cli/dist/src/session/tool-scheduler.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/tool-scheduler.js +0 -242
- package/vendor/agent-cli/dist/src/session/tool-scheduler.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/user-choice-policy.d.ts +0 -25
- package/vendor/agent-cli/dist/src/session/user-choice-policy.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/user-choice-policy.js +0 -70
- package/vendor/agent-cli/dist/src/session/user-choice-policy.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/user-choice.d.ts +0 -6
- package/vendor/agent-cli/dist/src/session/user-choice.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/user-choice.js +0 -101
- package/vendor/agent-cli/dist/src/session/user-choice.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/user-skill-compatibility.d.ts +0 -4
- package/vendor/agent-cli/dist/src/session/user-skill-compatibility.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/user-skill-compatibility.js +0 -25
- package/vendor/agent-cli/dist/src/session/user-skill-compatibility.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/user-skill-loaded.d.ts +0 -31
- package/vendor/agent-cli/dist/src/session/user-skill-loaded.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/user-skill-loaded.js +0 -105
- package/vendor/agent-cli/dist/src/session/user-skill-loaded.js.map +0 -1
- package/vendor/agent-cli/dist/src/session/user-skill-prompt.d.ts +0 -4
- package/vendor/agent-cli/dist/src/session/user-skill-prompt.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/session/user-skill-prompt.js +0 -15
- package/vendor/agent-cli/dist/src/session/user-skill-prompt.js.map +0 -1
- package/vendor/agent-cli/dist/src/shared/app-id.d.ts +0 -13
- package/vendor/agent-cli/dist/src/shared/app-id.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/shared/app-id.js +0 -25
- package/vendor/agent-cli/dist/src/shared/app-id.js.map +0 -1
- package/vendor/agent-cli/dist/src/shared/auth-headers.d.ts +0 -13
- package/vendor/agent-cli/dist/src/shared/auth-headers.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/shared/auth-headers.js +0 -16
- package/vendor/agent-cli/dist/src/shared/auth-headers.js.map +0 -1
- package/vendor/agent-cli/dist/src/shared/cli-version.d.ts +0 -3
- package/vendor/agent-cli/dist/src/shared/cli-version.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/shared/cli-version.js +0 -22
- package/vendor/agent-cli/dist/src/shared/cli-version.js.map +0 -1
- package/vendor/agent-cli/dist/src/shared/error-detail.d.ts +0 -14
- package/vendor/agent-cli/dist/src/shared/error-detail.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/shared/error-detail.js +0 -29
- package/vendor/agent-cli/dist/src/shared/error-detail.js.map +0 -1
- package/vendor/agent-cli/dist/src/shared/output-guard.d.ts +0 -36
- package/vendor/agent-cli/dist/src/shared/output-guard.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/shared/output-guard.js +0 -94
- package/vendor/agent-cli/dist/src/shared/output-guard.js.map +0 -1
- package/vendor/agent-cli/dist/src/shared/process-cwd.d.ts +0 -3
- package/vendor/agent-cli/dist/src/shared/process-cwd.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/shared/process-cwd.js +0 -11
- package/vendor/agent-cli/dist/src/shared/process-cwd.js.map +0 -1
- package/vendor/agent-cli/dist/src/shared/process-types.d.ts +0 -60
- package/vendor/agent-cli/dist/src/shared/process-types.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/shared/process-types.js +0 -10
- package/vendor/agent-cli/dist/src/shared/process-types.js.map +0 -1
- package/vendor/agent-cli/dist/src/shared/replace-file.d.ts +0 -3
- package/vendor/agent-cli/dist/src/shared/replace-file.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/shared/replace-file.js +0 -34
- package/vendor/agent-cli/dist/src/shared/replace-file.js.map +0 -1
- package/vendor/agent-cli/dist/src/shared/server-headers.d.ts +0 -7
- package/vendor/agent-cli/dist/src/shared/server-headers.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/shared/server-headers.js +0 -113
- package/vendor/agent-cli/dist/src/shared/server-headers.js.map +0 -1
- package/vendor/agent-cli/dist/src/shared/shell-runtime.d.ts +0 -47
- package/vendor/agent-cli/dist/src/shared/shell-runtime.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/shared/shell-runtime.js +0 -210
- package/vendor/agent-cli/dist/src/shared/shell-runtime.js.map +0 -1
- package/vendor/agent-cli/dist/src/shared/types.d.ts +0 -513
- package/vendor/agent-cli/dist/src/shared/types.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/shared/types.js +0 -2
- package/vendor/agent-cli/dist/src/shared/types.js.map +0 -1
- package/vendor/agent-cli/dist/src/shared/user-choice.d.ts +0 -41
- package/vendor/agent-cli/dist/src/shared/user-choice.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/shared/user-choice.js +0 -2
- package/vendor/agent-cli/dist/src/shared/user-choice.js.map +0 -1
- package/vendor/agent-cli/dist/src/tools/artifact-publisher.d.ts +0 -9
- package/vendor/agent-cli/dist/src/tools/artifact-publisher.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/tools/artifact-publisher.js +0 -85
- package/vendor/agent-cli/dist/src/tools/artifact-publisher.js.map +0 -1
- package/vendor/agent-cli/dist/src/tools/command-executor.d.ts +0 -33
- package/vendor/agent-cli/dist/src/tools/command-executor.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/tools/command-executor.js +0 -133
- package/vendor/agent-cli/dist/src/tools/command-executor.js.map +0 -1
- package/vendor/agent-cli/dist/src/tools/context-program-publish.d.ts +0 -16
- package/vendor/agent-cli/dist/src/tools/context-program-publish.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/tools/context-program-publish.js +0 -104
- package/vendor/agent-cli/dist/src/tools/context-program-publish.js.map +0 -1
- package/vendor/agent-cli/dist/src/tools/context-program.d.ts +0 -21
- package/vendor/agent-cli/dist/src/tools/context-program.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/tools/context-program.js +0 -233
- package/vendor/agent-cli/dist/src/tools/context-program.js.map +0 -1
- package/vendor/agent-cli/dist/src/tools/file-ops.d.ts +0 -52
- package/vendor/agent-cli/dist/src/tools/file-ops.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/tools/file-ops.js +0 -403
- package/vendor/agent-cli/dist/src/tools/file-ops.js.map +0 -1
- package/vendor/agent-cli/dist/src/tools/file-search.d.ts +0 -29
- package/vendor/agent-cli/dist/src/tools/file-search.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/tools/file-search.js +0 -98
- package/vendor/agent-cli/dist/src/tools/file-search.js.map +0 -1
- package/vendor/agent-cli/dist/src/tools/file-stat.d.ts +0 -9
- package/vendor/agent-cli/dist/src/tools/file-stat.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/tools/file-stat.js +0 -29
- package/vendor/agent-cli/dist/src/tools/file-stat.js.map +0 -1
- package/vendor/agent-cli/dist/src/tools/local-hands.d.ts +0 -58
- package/vendor/agent-cli/dist/src/tools/local-hands.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/tools/local-hands.js +0 -330
- package/vendor/agent-cli/dist/src/tools/local-hands.js.map +0 -1
- package/vendor/agent-cli/dist/src/tools/ripgrep-search.d.ts +0 -24
- package/vendor/agent-cli/dist/src/tools/ripgrep-search.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/tools/ripgrep-search.js +0 -160
- package/vendor/agent-cli/dist/src/tools/ripgrep-search.js.map +0 -1
- package/vendor/agent-cli/dist/src/tools/tool-contract.gen.d.ts +0 -69
- package/vendor/agent-cli/dist/src/tools/tool-contract.gen.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/tools/tool-contract.gen.js +0 -68
- package/vendor/agent-cli/dist/src/tools/tool-contract.gen.js.map +0 -1
- package/vendor/agent-cli/dist/src/tools/tool-timeout.d.ts +0 -29
- package/vendor/agent-cli/dist/src/tools/tool-timeout.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/tools/tool-timeout.js +0 -88
- package/vendor/agent-cli/dist/src/tools/tool-timeout.js.map +0 -1
- package/vendor/agent-cli/dist/src/tools/write-guard.d.ts +0 -42
- package/vendor/agent-cli/dist/src/tools/write-guard.d.ts.map +0 -1
- package/vendor/agent-cli/dist/src/tools/write-guard.js +0 -34
- package/vendor/agent-cli/dist/src/tools/write-guard.js.map +0 -1
- package/vendor/agent-cli/package.json +0 -29
- /package/resources/js/{context/skills/export-config/scripts → project/scripts/config-export}/assert-asset-wiring.mjs +0 -0
- /package/resources/js3d/{context/skills/export-config/scripts → project/scripts/config-export}/assert-asset-wiring.mjs +0 -0
- /package/resources/js3d/{context/skills/export-config/scripts → project/scripts/config-export}/sync-asset-controls.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt/project/scripts/skill-modules/export-config → targets/codebuddy/js/js/context/skills/export-config/assets/tooling}/cli.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt/project/scripts/skill-modules/export-config → targets/codebuddy/js/js/context/skills/export-config/assets/tooling}/config.d.mts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt/project/scripts/skill-modules/export-config → targets/codebuddy/js/js/context/skills/export-config/assets/tooling}/config.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt/project/scripts/skill-modules/export-config → targets/codebuddy/js/js/context/skills/export-config/assets/tooling}/project.d.mts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt/project/scripts/skill-modules/export-config → targets/codebuddy/js/js/context/skills/export-config/assets/tooling}/project.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt/project/scripts/skill-modules/export-config → targets/codebuddy/js/js/context/skills/export-config/assets/tooling}/vite.d.mts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt/project/scripts/skill-modules/export-config → targets/codebuddy/js/js/context/skills/export-config/assets/tooling}/vite.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/game-runtime.json +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/platform/identity/qq-ai-game-sdk.min.js +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/platform/identity/qq-session.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/platform/identity/shared.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/platform/platform-capture-video.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/platform/platform-service.d.mts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/platform/platform-service.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/platform/platform.d.mts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/platform/platform.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/release.json +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/tooling/cli.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/tooling/project.d.mts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/tooling/project.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/tooling/vite.d.mts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/tooling/vite.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/tools/assets.d.mts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/tools/assets.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/tools/astc.d.mts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/runtime/lightgame/1.1.0/tools/astc.mjs +0 -0
- /package/resources/{js/project/runtime/lightgame/1.0.0/platform → targets/codebuddy/js/js/project/scripts/skill-modules/export-config}/config.d.mts +0 -0
- /package/resources/{js/project/runtime/lightgame/1.0.0/platform → targets/codebuddy/js/js/project/scripts/skill-modules/export-config}/config.mjs +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/scripts/skill-modules/export-config/installed.json +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/src/display/ui-stage.ts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/src/display/viewport.ts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/src/main.ts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/src/platform.ts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/src/screenUi.ts +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/src/style.css +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/tsconfig.json +0 -0
- /package/resources/{js/context/skills/lightgame-runtime-adapt → targets/codebuddy/js/js}/project/vite.config.ts +0 -0
- /package/resources/{js3d/project/runtime/lightgame/1.0.0/platform → targets/codebuddy/js3d/js3d/context/skills/export-config/assets/tooling}/config.d.mts +0 -0
- /package/resources/{js3d/project/runtime/lightgame/1.0.0/platform → targets/codebuddy/js3d/js3d/context/skills/export-config/assets/tooling}/config.mjs +0 -0
- /package/resources/{js/context/skills/platform-services/assets/modules → targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform}/identity/qq-ai-game-sdk.min.js +0 -0
- /package/resources/{js/context/skills/platform-services/assets/modules → targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform}/identity/qq-session.mjs +0 -0
- /package/resources/{js/context/skills/platform-services/assets/modules → targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform}/identity/shared.mjs +0 -0
- /package/resources/{js/project/runtime/lightgame/1.0.0 → targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0}/platform/platform-capture-video.mjs +0 -0
- /package/resources/{js/context/skills/platform-services/assets/modules → targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform}/platform-service.d.mts +0 -0
- /package/resources/{js/context/skills/platform-services/assets/modules → targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0/platform}/platform-service.mjs +0 -0
- /package/resources/{js3d/project/runtime/lightgame/1.0.0 → targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0}/platform/platform.d.mts +0 -0
- /package/resources/{js/project/runtime/lightgame/1.0.0 → targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0}/tools/assets.d.mts +0 -0
- /package/resources/{js3d/project/runtime/lightgame/1.0.0 → targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0}/tools/assets.mjs +0 -0
- /package/resources/{js/project/runtime/lightgame/1.0.0 → targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0}/tools/astc.d.mts +0 -0
- /package/resources/{js3d/project/runtime/lightgame/1.0.0 → targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0}/tools/astc.mjs +0 -0
- /package/resources/{js3d/project/runtime/lightgame/1.0.0 → targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0}/tools/glb.d.mts +0 -0
- /package/resources/{js3d/project/runtime/lightgame/1.0.0 → targets/codebuddy/js3d/js3d/project/runtime/lightgame/1.1.0}/tools/glb.mjs +0 -0
- /package/resources/{js3d/context/skills/resolution-adaptation/assets → targets/codebuddy/js3d/js3d/project/src}/display/ui-stage.ts +0 -0
- /package/resources/{js3d/context/skills/resolution-adaptation/assets → targets/codebuddy/js3d/js3d/project/src}/display/viewport.ts +0 -0
- /package/resources/{js3d/context/skills/platform-services/assets/modules → targets/codex/js/js/project/runtime/lightgame/1.1.0/platform}/identity/qq-ai-game-sdk.min.js +0 -0
- /package/resources/{js3d/context/skills/platform-services/assets/modules → targets/codex/js/js/project/runtime/lightgame/1.1.0/platform}/identity/qq-session.mjs +0 -0
- /package/resources/{js3d/context/skills/platform-services/assets/modules → targets/codex/js/js/project/runtime/lightgame/1.1.0/platform}/identity/shared.mjs +0 -0
- /package/resources/{js3d/project/runtime/lightgame/1.0.0 → targets/codex/js/js/project/runtime/lightgame/1.1.0}/platform/platform-capture-video.mjs +0 -0
- /package/resources/{js3d/context/skills/platform-services/assets/modules → targets/codex/js/js/project/runtime/lightgame/1.1.0/platform}/platform-service.d.mts +0 -0
- /package/resources/{js3d/context/skills/platform-services/assets/modules → targets/codex/js/js/project/runtime/lightgame/1.1.0/platform}/platform-service.mjs +0 -0
- /package/resources/{js/project/runtime/lightgame/1.0.0 → targets/codex/js/js/project/runtime/lightgame/1.1.0}/platform/platform.d.mts +0 -0
- /package/resources/{js/project/runtime/lightgame/1.0.0 → targets/codex/js/js/project/runtime/lightgame/1.1.0}/platform/platform.mjs +0 -0
- /package/resources/{js3d/project/runtime/lightgame/1.0.0 → targets/codex/js/js/project/runtime/lightgame/1.1.0}/tools/assets.d.mts +0 -0
- /package/resources/{js/project/runtime/lightgame/1.0.0 → targets/codex/js/js/project/runtime/lightgame/1.1.0}/tools/assets.mjs +0 -0
- /package/resources/{js3d/project/runtime/lightgame/1.0.0 → targets/codex/js/js/project/runtime/lightgame/1.1.0}/tools/astc.d.mts +0 -0
- /package/resources/{js/project/runtime/lightgame/1.0.0 → targets/codex/js/js/project/runtime/lightgame/1.1.0}/tools/astc.mjs +0 -0
- /package/resources/{js/context/skills/resolution-adaptation/assets → targets/codex/js/js/project/src}/display/ui-stage.ts +0 -0
- /package/resources/{js/context/skills/resolution-adaptation/assets → targets/codex/js/js/project/src}/display/viewport.ts +0 -0
|
@@ -0,0 +1,1716 @@
|
|
|
1
|
+
// vendor/agent-cli/dist/src/protocol/messages/errors.gen.js
|
|
2
|
+
var ErrRunCancelled = { code: 70024, message: "\u672C\u6B21\u8FD0\u884C\u5DF2\u53D6\u6D88" };
|
|
3
|
+
var ErrRunPreparationTimeout = { code: 70027, message: "\u8FD0\u884C\u51C6\u5907\u8D85\u65F6\uFF0C\u8BF7\u68C0\u67E5\u7F51\u7EDC\u540E\u91CD\u8BD5" };
|
|
4
|
+
var ErrDependencyInstallFailed = { code: 70030, message: "\u5DE5\u7A0B\u4F9D\u8D56\u5B89\u88C5\u5931\u8D25\uFF0C\u8BF7\u7A0D\u540E\u91CD\u8BD5" };
|
|
5
|
+
var ErrDependencyInstallTimeout = { code: 70031, message: "\u5DE5\u7A0B\u4F9D\u8D56\u5B89\u88C5\u8D85\u65F6\uFF0C\u8BF7\u7A0D\u540E\u91CD\u8BD5" };
|
|
6
|
+
var ErrInvalidConfiguration = { code: 70402, message: "\u670D\u52A1\u914D\u7F6E\u65E0\u6548" };
|
|
7
|
+
|
|
8
|
+
// vendor/agent-cli/dist/src/protocol/link/envelope.js
|
|
9
|
+
var LinkError = class extends Error {
|
|
10
|
+
code;
|
|
11
|
+
constructor(err, cause) {
|
|
12
|
+
super(err.message, cause === void 0 ? void 0 : { cause });
|
|
13
|
+
this.name = "AgentRunError";
|
|
14
|
+
this.code = err.code;
|
|
15
|
+
}
|
|
16
|
+
/** JSON 输出只包含公开字段,不传出内部原因。 */
|
|
17
|
+
toJSON() {
|
|
18
|
+
return { code: this.code, message: this.message };
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
// vendor/agent-cli/dist/src/component/preparation.js
|
|
23
|
+
var DEFAULT_PREPARATION_TIMEOUT_MS = 12e4;
|
|
24
|
+
async function withPreparation(options, work) {
|
|
25
|
+
const timeoutMs = options.timeoutMs ?? DEFAULT_PREPARATION_TIMEOUT_MS;
|
|
26
|
+
if (!Number.isFinite(timeoutMs) || timeoutMs <= 0 || timeoutMs > 36e5) {
|
|
27
|
+
throw new LinkError(ErrInvalidConfiguration, "preparation timeout must be within 1..3600000ms");
|
|
28
|
+
}
|
|
29
|
+
const controller = new AbortController();
|
|
30
|
+
const onAbort = () => controller.abort(options.signal?.reason instanceof LinkError ? options.signal.reason : new LinkError(ErrRunCancelled));
|
|
31
|
+
if (options.signal?.aborted)
|
|
32
|
+
onAbort();
|
|
33
|
+
else
|
|
34
|
+
options.signal?.addEventListener("abort", onAbort, { once: true });
|
|
35
|
+
const timer = setTimeout(() => {
|
|
36
|
+
if (!controller.signal.aborted)
|
|
37
|
+
controller.abort(options.diagnostics?.timeoutError(timeoutMs) ?? new LinkError(ErrRunPreparationTimeout));
|
|
38
|
+
}, timeoutMs);
|
|
39
|
+
try {
|
|
40
|
+
controller.signal.throwIfAborted();
|
|
41
|
+
const result = await work(controller.signal);
|
|
42
|
+
controller.signal.throwIfAborted();
|
|
43
|
+
return result;
|
|
44
|
+
} catch (err) {
|
|
45
|
+
if (controller.signal.aborted)
|
|
46
|
+
throw controller.signal.reason;
|
|
47
|
+
throw err;
|
|
48
|
+
} finally {
|
|
49
|
+
clearTimeout(timer);
|
|
50
|
+
options.signal?.removeEventListener("abort", onAbort);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
// vendor/agent-cli/dist/src/shared/output-guard.js
|
|
55
|
+
var DEFAULT_MAX_OUTPUT_BYTES = 128 * 1024;
|
|
56
|
+
var STREAM_COLLECT_LIMIT_BYTES = 1024 * 1024;
|
|
57
|
+
var MIN_BINARY_RUN_LENGTH = 4096;
|
|
58
|
+
var BINARY_RUN_RE = new RegExp(`[A-Za-z0-9+/=_-]{${MIN_BINARY_RUN_LENGTH},}`, "g");
|
|
59
|
+
|
|
60
|
+
// vendor/agent-cli/dist/src/shared/shell-runtime.js
|
|
61
|
+
import fs from "node:fs";
|
|
62
|
+
import { spawn } from "node:child_process";
|
|
63
|
+
var IS_WINDOWS = process.platform === "win32";
|
|
64
|
+
var currentRuntime = {
|
|
65
|
+
platform: process.platform,
|
|
66
|
+
env: process.env,
|
|
67
|
+
isFile: (candidate) => {
|
|
68
|
+
try {
|
|
69
|
+
return fs.statSync(candidate).isFile();
|
|
70
|
+
} catch {
|
|
71
|
+
return false;
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
pathExists: (candidate) => fs.existsSync(candidate)
|
|
75
|
+
};
|
|
76
|
+
function killProcessTree(pid) {
|
|
77
|
+
if (!pid)
|
|
78
|
+
return Promise.resolve();
|
|
79
|
+
if (IS_WINDOWS) {
|
|
80
|
+
return new Promise((resolve) => {
|
|
81
|
+
let settled = false;
|
|
82
|
+
const finish = () => {
|
|
83
|
+
if (settled)
|
|
84
|
+
return;
|
|
85
|
+
settled = true;
|
|
86
|
+
resolve();
|
|
87
|
+
};
|
|
88
|
+
const fallback = () => {
|
|
89
|
+
try {
|
|
90
|
+
process.kill(pid);
|
|
91
|
+
} catch {
|
|
92
|
+
}
|
|
93
|
+
finish();
|
|
94
|
+
};
|
|
95
|
+
try {
|
|
96
|
+
const killer = spawn("taskkill", ["/pid", String(pid), "/T", "/F"], {
|
|
97
|
+
stdio: "ignore",
|
|
98
|
+
windowsHide: true
|
|
99
|
+
});
|
|
100
|
+
killer.once("error", fallback);
|
|
101
|
+
killer.once("close", finish);
|
|
102
|
+
} catch {
|
|
103
|
+
fallback();
|
|
104
|
+
}
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
try {
|
|
108
|
+
process.kill(-pid, "SIGKILL");
|
|
109
|
+
} catch {
|
|
110
|
+
try {
|
|
111
|
+
process.kill(pid, "SIGKILL");
|
|
112
|
+
} catch {
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
return Promise.resolve();
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
// vendor/agent-cli/dist/src/component/execution.js
|
|
119
|
+
import fs2 from "node:fs";
|
|
120
|
+
|
|
121
|
+
// vendor/agent-cli/dist/src/component/process-isolation.js
|
|
122
|
+
import { AsyncLocalStorage } from "node:async_hooks";
|
|
123
|
+
import { mkdtemp, rm, realpath, stat } from "node:fs/promises";
|
|
124
|
+
import path from "node:path";
|
|
125
|
+
import { fileURLToPath } from "node:url";
|
|
126
|
+
var scopes = new AsyncLocalStorage();
|
|
127
|
+
async function isolatedInvocation(file, args, options) {
|
|
128
|
+
const scope = scopes.getStore();
|
|
129
|
+
if (!scope || options.trustedNetwork)
|
|
130
|
+
return { file, args, options };
|
|
131
|
+
const cwd = await realpath(options.cwd);
|
|
132
|
+
const mounts = /* @__PURE__ */ new Set([scope.directory]);
|
|
133
|
+
for (const source of options.readOnlyDirectories ?? []) {
|
|
134
|
+
const canonical = await realpath(source);
|
|
135
|
+
if (canonical !== source || !(await stat(canonical)).isDirectory())
|
|
136
|
+
throw Error("redirected frozen context");
|
|
137
|
+
mounts.add(canonical);
|
|
138
|
+
}
|
|
139
|
+
const within = (root, target) => {
|
|
140
|
+
const relative = path.relative(root, target);
|
|
141
|
+
return relative !== ".." && !relative.startsWith("../") && !path.isAbsolute(relative);
|
|
142
|
+
};
|
|
143
|
+
if (!within(scope.workspace, cwd) && ![...mounts].some((root) => within(root, cwd)))
|
|
144
|
+
throw Error("isolated cwd outside approved directories");
|
|
145
|
+
const bwrapArgs = ["--unshare-user", "--unshare-pid", "--unshare-net", "--unshare-ipc", "--unshare-uts", "--unshare-cgroup", "--uid", "10001", "--gid", "10001", "--die-with-parent", "--new-session", "--ro-bind", "/", "/", "--tmpfs", "/tmp", "--proc", "/proc", "--dev", "/dev", "--bind", scope.workspace, scope.workspace];
|
|
146
|
+
for (const source of mounts)
|
|
147
|
+
bwrapArgs.push("--ro-bind", source, source);
|
|
148
|
+
bwrapArgs.push("--chdir", cwd, "--", process.execPath, fileURLToPath(new URL("./isolated-launcher.js", import.meta.url)), scope.directory);
|
|
149
|
+
const env = { ...options.env };
|
|
150
|
+
for (const key of Object.keys(env))
|
|
151
|
+
if (key.startsWith("CRAFT_WEB_") || key === "CRAFT_BWRAP_PATH" || ["NODE_OPTIONS", "NODE_EXTRA_CA_CERTS", "AGENT_CLI_TOKEN"].includes(key))
|
|
152
|
+
delete env[key];
|
|
153
|
+
return { file: scope.bwrap, args: bwrapArgs, options: {
|
|
154
|
+
...options,
|
|
155
|
+
cwd,
|
|
156
|
+
env,
|
|
157
|
+
stdin: JSON.stringify({ file, args, env, stdin: options.stdin ?? "" })
|
|
158
|
+
} };
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
// vendor/agent-cli/dist/src/component/execution.js
|
|
162
|
+
import path3 from "node:path";
|
|
163
|
+
import { spawn as spawn2 } from "node:child_process";
|
|
164
|
+
|
|
165
|
+
// vendor/agent-cli/dist/src/shared/process-cwd.js
|
|
166
|
+
import path2 from "node:path";
|
|
167
|
+
function nativeProcessCwd(cwd) {
|
|
168
|
+
return process.platform === "win32" && path2.resolve(cwd).length >= 260 ? path2.toNamespacedPath(cwd) : cwd;
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
// vendor/agent-cli/dist/src/component/browser-queue.js
|
|
172
|
+
import { randomUUID } from "node:crypto";
|
|
173
|
+
var BrowserExecutionQueue = class {
|
|
174
|
+
active;
|
|
175
|
+
waiting = [];
|
|
176
|
+
totals = /* @__PURE__ */ new Map();
|
|
177
|
+
snapshot() {
|
|
178
|
+
return {
|
|
179
|
+
active: this.active ? { ...this.active } : null,
|
|
180
|
+
waiting: this.waiting.map((item) => ({ ...item.entry })),
|
|
181
|
+
totals: Object.fromEntries([...this.totals].map(([key, value]) => [key, { ...value }]))
|
|
182
|
+
};
|
|
183
|
+
}
|
|
184
|
+
async run(workspace, signal, action) {
|
|
185
|
+
signal?.throwIfAborted();
|
|
186
|
+
const entry = { id: randomUUID(), workspace, queuedAt: Date.now() };
|
|
187
|
+
await new Promise((resolve, reject) => {
|
|
188
|
+
const waiter = { entry, signal, grant: resolve, abort: () => {
|
|
189
|
+
const index = this.waiting.indexOf(waiter);
|
|
190
|
+
if (index < 0)
|
|
191
|
+
return;
|
|
192
|
+
this.waiting.splice(index, 1);
|
|
193
|
+
signal?.removeEventListener("abort", waiter.abort);
|
|
194
|
+
reject(signal?.reason ?? Error("Browser queue cancelled"));
|
|
195
|
+
} };
|
|
196
|
+
this.waiting.push(waiter);
|
|
197
|
+
signal?.addEventListener("abort", waiter.abort, { once: true });
|
|
198
|
+
if (signal?.aborted)
|
|
199
|
+
waiter.abort();
|
|
200
|
+
this.drain();
|
|
201
|
+
});
|
|
202
|
+
try {
|
|
203
|
+
signal?.throwIfAborted();
|
|
204
|
+
return await action();
|
|
205
|
+
} finally {
|
|
206
|
+
const total = this.totals.get(workspace) ?? { completed: 0, waitMs: 0 };
|
|
207
|
+
total.completed++;
|
|
208
|
+
total.waitMs += entry.startedAt - entry.queuedAt;
|
|
209
|
+
this.totals.set(workspace, total);
|
|
210
|
+
this.active = void 0;
|
|
211
|
+
this.drain();
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
drain() {
|
|
215
|
+
if (this.active)
|
|
216
|
+
return;
|
|
217
|
+
const next = this.waiting.shift();
|
|
218
|
+
if (!next)
|
|
219
|
+
return;
|
|
220
|
+
next.signal?.removeEventListener("abort", next.abort);
|
|
221
|
+
next.entry.startedAt = Date.now();
|
|
222
|
+
this.active = next.entry;
|
|
223
|
+
next.grant();
|
|
224
|
+
}
|
|
225
|
+
};
|
|
226
|
+
var queue = new BrowserExecutionQueue();
|
|
227
|
+
var enabled = false;
|
|
228
|
+
function withBrowserExecution(workspace, signal, action) {
|
|
229
|
+
return enabled ? queue.run(workspace, signal, action) : action();
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
// vendor/agent-cli/dist/src/component/execution.js
|
|
233
|
+
function resolveProgram(program, args, env) {
|
|
234
|
+
if (!program.trim() || program.includes("\0"))
|
|
235
|
+
throw new Error("\u7A0B\u5E8F\u540D\u4E0D\u80FD\u4E3A\u7A7A\u6216\u542B NUL");
|
|
236
|
+
if (program === "node" || program === "node.exe")
|
|
237
|
+
return { file: process.execPath, args };
|
|
238
|
+
if (["npm", "npm.cmd", "npx", "npx.cmd"].includes(program)) {
|
|
239
|
+
const name = program.startsWith("npx") ? "npx-cli.js" : "npm-cli.js";
|
|
240
|
+
const dirs = [path3.dirname(process.execPath), ...(env.PATH ?? env.Path ?? "").split(path3.delimiter)];
|
|
241
|
+
for (const dir of dirs) {
|
|
242
|
+
if (!dir)
|
|
243
|
+
continue;
|
|
244
|
+
const candidates = [
|
|
245
|
+
path3.join(dir, "node_modules", "npm", "bin", name),
|
|
246
|
+
path3.resolve(dir, "..", "lib", "node_modules", "npm", "bin", name),
|
|
247
|
+
path3.resolve(dir, "..", "share", "nodejs", "npm", "bin", name)
|
|
248
|
+
];
|
|
249
|
+
for (const candidate of candidates) {
|
|
250
|
+
if (fs2.existsSync(candidate))
|
|
251
|
+
return { file: process.execPath, args: [candidate, ...args] };
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
if (process.platform === "win32")
|
|
255
|
+
throw new Error("\u672A\u627E\u5230 npm \u7684 JS \u5165\u53E3\uFF0C\u8BF7\u914D\u7F6E\u5B8C\u6574\u7684 Node/npm \u8FD0\u884C\u65F6");
|
|
256
|
+
}
|
|
257
|
+
if (process.platform === "win32" && /\.(cmd|bat)$/i.test(program)) {
|
|
258
|
+
throw new Error("\u6279\u5904\u7406\u6587\u4EF6\u9700\u8981\u901A\u8FC7\u660E\u786E\u7684 Shell \u6267\u884C\uFF1B\u7A0B\u5E8F\u6267\u884C\u53EA\u63A5\u53D7\u539F\u751F\u7A0B\u5E8F\u6216 Node/npm \u5165\u53E3");
|
|
259
|
+
}
|
|
260
|
+
return { file: program, args };
|
|
261
|
+
}
|
|
262
|
+
function processEnvironment(extra = {}) {
|
|
263
|
+
const inherited = { ...process.env };
|
|
264
|
+
for (const key of Object.keys(inherited)) {
|
|
265
|
+
if (key.startsWith("PLATFORM_") || key === "AGENT_CLI_TOKEN")
|
|
266
|
+
delete inherited[key];
|
|
267
|
+
}
|
|
268
|
+
const env = { ...inherited, ...extra, PYTHONIOENCODING: "utf-8", PYTHONUTF8: "1" };
|
|
269
|
+
delete env.AGENT_CLI_TOKEN;
|
|
270
|
+
return env;
|
|
271
|
+
}
|
|
272
|
+
function runProcess(file, args, options) {
|
|
273
|
+
if (options.env.CRAFT_RUNTIME_REQUIREMENTS === "browser") {
|
|
274
|
+
return withBrowserExecution(options.cwd, options.signal, () => runOwnedProcess(file, args, options));
|
|
275
|
+
}
|
|
276
|
+
return runOwnedProcess(file, args, options);
|
|
277
|
+
}
|
|
278
|
+
async function runOwnedProcess(file, args, options) {
|
|
279
|
+
const invocation = await isolatedInvocation(file, args, options);
|
|
280
|
+
file = invocation.file;
|
|
281
|
+
args = invocation.args;
|
|
282
|
+
options = invocation.options;
|
|
283
|
+
if (options.signal?.aborted) {
|
|
284
|
+
return Promise.resolve({ exitCode: -1, signal: null, stdout: "", stderr: "", timedOut: false, aborted: true });
|
|
285
|
+
}
|
|
286
|
+
return new Promise((resolve, reject) => {
|
|
287
|
+
const child = spawn2(file, args, {
|
|
288
|
+
cwd: nativeProcessCwd(options.cwd),
|
|
289
|
+
env: options.env,
|
|
290
|
+
windowsHide: true,
|
|
291
|
+
detached: process.platform !== "win32",
|
|
292
|
+
stdio: ["pipe", "pipe", "pipe"]
|
|
293
|
+
});
|
|
294
|
+
const stdout = [];
|
|
295
|
+
const stderr = [];
|
|
296
|
+
let stdoutBytes = 0;
|
|
297
|
+
let stderrBytes = 0;
|
|
298
|
+
let timedOut = false;
|
|
299
|
+
let aborted = false;
|
|
300
|
+
let settled = false;
|
|
301
|
+
let processTreeStopped;
|
|
302
|
+
const stopProcessTree = () => {
|
|
303
|
+
processTreeStopped ??= killProcessTree(child.pid);
|
|
304
|
+
return processTreeStopped;
|
|
305
|
+
};
|
|
306
|
+
const collect = (kind, chunk) => {
|
|
307
|
+
const used = kind === "stdout" ? stdoutBytes : stderrBytes;
|
|
308
|
+
const part = chunk.subarray(0, Math.max(0, STREAM_COLLECT_LIMIT_BYTES - used));
|
|
309
|
+
if (part.length === 0)
|
|
310
|
+
return;
|
|
311
|
+
if (kind === "stdout") {
|
|
312
|
+
stdout.push(part);
|
|
313
|
+
stdoutBytes += part.length;
|
|
314
|
+
} else {
|
|
315
|
+
stderr.push(part);
|
|
316
|
+
stderrBytes += part.length;
|
|
317
|
+
}
|
|
318
|
+
};
|
|
319
|
+
child.stdout.on("data", (chunk) => collect("stdout", chunk));
|
|
320
|
+
child.stderr.on("data", (chunk) => collect("stderr", chunk));
|
|
321
|
+
const timer = setTimeout(() => {
|
|
322
|
+
timedOut = true;
|
|
323
|
+
void stopProcessTree();
|
|
324
|
+
}, options.timeoutMs);
|
|
325
|
+
const onAbort = () => {
|
|
326
|
+
aborted = true;
|
|
327
|
+
void stopProcessTree();
|
|
328
|
+
};
|
|
329
|
+
options.signal?.addEventListener("abort", onAbort, { once: true });
|
|
330
|
+
if (options.signal?.aborted)
|
|
331
|
+
onAbort();
|
|
332
|
+
const finish = async (error, code = null, signal = null) => {
|
|
333
|
+
if (settled)
|
|
334
|
+
return;
|
|
335
|
+
settled = true;
|
|
336
|
+
clearTimeout(timer);
|
|
337
|
+
options.signal?.removeEventListener("abort", onAbort);
|
|
338
|
+
await processTreeStopped;
|
|
339
|
+
if (error) {
|
|
340
|
+
reject(error);
|
|
341
|
+
return;
|
|
342
|
+
}
|
|
343
|
+
resolve({ signal, exitCode: timedOut || aborted ? -1 : code ?? -1, stdout: Buffer.concat(stdout).toString("utf8"), stderr: Buffer.concat(stderr).toString("utf8"), timedOut, aborted });
|
|
344
|
+
};
|
|
345
|
+
child.on("error", (error) => {
|
|
346
|
+
void finish(error);
|
|
347
|
+
});
|
|
348
|
+
child.on("close", (code, signal) => {
|
|
349
|
+
void finish(void 0, code, signal);
|
|
350
|
+
});
|
|
351
|
+
const onOutputError = (error) => {
|
|
352
|
+
if (settled)
|
|
353
|
+
return;
|
|
354
|
+
void stopProcessTree();
|
|
355
|
+
void finish(error);
|
|
356
|
+
};
|
|
357
|
+
child.stdout.on("error", onOutputError);
|
|
358
|
+
child.stderr.on("error", onOutputError);
|
|
359
|
+
child.stdin.on("error", (error) => {
|
|
360
|
+
if (error.code !== "EPIPE" && error.code !== "ERR_STREAM_DESTROYED") {
|
|
361
|
+
void stopProcessTree();
|
|
362
|
+
void finish(error);
|
|
363
|
+
}
|
|
364
|
+
});
|
|
365
|
+
child.stdin.end(options.stdin ?? "");
|
|
366
|
+
});
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
// vendor/agent-cli/dist/src/component/runtime.js
|
|
370
|
+
import os from "node:os";
|
|
371
|
+
import path4 from "node:path";
|
|
372
|
+
import { createRequire } from "node:module";
|
|
373
|
+
var probeScript = [
|
|
374
|
+
"const fs=require('node:fs');const {chromium}=require(process.argv[1]);",
|
|
375
|
+
"const candidates=JSON.parse(process.argv[2]);",
|
|
376
|
+
"candidates.push({exe:chromium.executablePath(),source:'managed'});",
|
|
377
|
+
"(async()=>{const failures=[];for(const item of candidates){",
|
|
378
|
+
"if(!fs.existsSync(item.exe))continue;let browser;",
|
|
379
|
+
"try{browser=await chromium.launch({executablePath:item.exe,headless:true,timeout:15000,chromiumSandbox:true,args:['--disable-dev-shm-usage','--enable-unsafe-swiftshader']});",
|
|
380
|
+
"await browser.close();console.log(JSON.stringify({exe:item.exe,source:item.source}));return;",
|
|
381
|
+
"}catch(e){if(browser)await browser.close().catch(()=>{});failures.push(item.source+': '+e.message);}}",
|
|
382
|
+
"console.log(JSON.stringify({missing:!fs.existsSync(chromium.executablePath()),failures}));})().catch(e=>{console.error(e.message);process.exit(1)});"
|
|
383
|
+
].join("\n");
|
|
384
|
+
function playwrightEntry(cwd, env) {
|
|
385
|
+
const roots = [
|
|
386
|
+
env.PLAYWRIGHT_PACKAGE_ROOT,
|
|
387
|
+
path4.join(cwd, "node_modules"),
|
|
388
|
+
...(env.NODE_PATH ?? "").split(path4.delimiter),
|
|
389
|
+
path4.dirname(process.execPath),
|
|
390
|
+
"/opt/js-toolchain/node_modules",
|
|
391
|
+
"/usr/local/lib/node_modules",
|
|
392
|
+
"/usr/lib/node_modules"
|
|
393
|
+
].filter((root) => !!root);
|
|
394
|
+
const anchors = [...roots.map((root) => path4.join(root, "__agent_runtime.cjs")), import.meta.url];
|
|
395
|
+
for (const anchor of anchors) {
|
|
396
|
+
try {
|
|
397
|
+
return createRequire(anchor).resolve("playwright");
|
|
398
|
+
} catch (error) {
|
|
399
|
+
if (error.code !== "MODULE_NOT_FOUND")
|
|
400
|
+
throw error;
|
|
401
|
+
}
|
|
402
|
+
}
|
|
403
|
+
throw new Error("\u6D4F\u89C8\u5668\u80FD\u529B\u9700\u8981 Playwright API \u5305\uFF1B\u8BF7\u4F7F\u7528\u542B\u8BE5\u80FD\u529B\u7684\u5BA2\u6237\u7AEF\u8FD0\u884C\u65F6\u6216\u5728\u6267\u884C\u7AEF\u5B89\u88C5 playwright\u3002");
|
|
404
|
+
}
|
|
405
|
+
function browserCandidates(env) {
|
|
406
|
+
const explicit = env.CRAFT_BROWSER_EXECUTABLE || env.UE_CHECK_BROWSER || env.CHROME_PATH;
|
|
407
|
+
const dirs = process.platform === "win32" ? [
|
|
408
|
+
env.PROGRAMFILES,
|
|
409
|
+
env["ProgramFiles(x86)"],
|
|
410
|
+
env.LOCALAPPDATA
|
|
411
|
+
].filter((value) => !!value) : [];
|
|
412
|
+
const paths = process.platform === "win32" ? dirs.flatMap((dir) => [
|
|
413
|
+
path4.join(dir, "Google", "Chrome", "Application", "chrome.exe"),
|
|
414
|
+
path4.join(dir, "Microsoft", "Edge", "Application", "msedge.exe")
|
|
415
|
+
]) : process.platform === "darwin" ? [
|
|
416
|
+
"/Applications/Google Chrome.app/Contents/MacOS/Google Chrome",
|
|
417
|
+
"/Applications/Microsoft Edge.app/Contents/MacOS/Microsoft Edge"
|
|
418
|
+
] : ["/usr/bin/google-chrome", "/usr/bin/google-chrome-stable", "/usr/bin/microsoft-edge", "/usr/bin/chromium", "/usr/bin/chromium-browser"];
|
|
419
|
+
return [...new Set([explicit, ...paths].filter((value) => !!value))].map((exe) => ({ exe, source: exe === explicit ? "configured" : "system" }));
|
|
420
|
+
}
|
|
421
|
+
async function probe(entry, options, env) {
|
|
422
|
+
const candidates = browserCandidates(env);
|
|
423
|
+
const result = await runProcess(process.execPath, ["-e", probeScript, entry, JSON.stringify(candidates)], {
|
|
424
|
+
cwd: options.cwd,
|
|
425
|
+
env,
|
|
426
|
+
signal: options.signal,
|
|
427
|
+
timeoutMs: 12e4
|
|
428
|
+
});
|
|
429
|
+
if (result.aborted)
|
|
430
|
+
throw new Error("\u6D4F\u89C8\u5668\u8FD0\u884C\u65F6\u51C6\u5907\u5DF2\u53D6\u6D88");
|
|
431
|
+
if (result.exitCode !== 0)
|
|
432
|
+
throw new Error("\u6D4F\u89C8\u5668\u63A2\u6D4B\u5931\u8D25: " + result.stderr);
|
|
433
|
+
return JSON.parse(result.stdout);
|
|
434
|
+
}
|
|
435
|
+
async function prepareBrowserEnvironment(options) {
|
|
436
|
+
const env = processEnvironment(options.env);
|
|
437
|
+
const entry = playwrightEntry(options.cwd, env);
|
|
438
|
+
let state = await probe(entry, options, env);
|
|
439
|
+
if (!state.exe && state.missing && env.CRAFT_RUNTIME_POLICY !== "preinstalled") {
|
|
440
|
+
env.PLAYWRIGHT_BROWSERS_PATH ||= path4.join(process.platform === "win32" ? env.LOCALAPPDATA || os.homedir() : env.XDG_CACHE_HOME || path4.join(os.homedir(), ".cache"), "craft-agent", "runtime", "playwright");
|
|
441
|
+
state = await probe(entry, options, env);
|
|
442
|
+
if (!state.exe && state.missing) {
|
|
443
|
+
const pkgDir = path4.dirname(createRequire(entry).resolve("playwright/package.json"));
|
|
444
|
+
const result = await runProcess(process.execPath, [path4.join(pkgDir, "cli.js"), "install", "chromium"], {
|
|
445
|
+
cwd: options.cwd,
|
|
446
|
+
env,
|
|
447
|
+
signal: options.signal,
|
|
448
|
+
timeoutMs: 3e5
|
|
449
|
+
});
|
|
450
|
+
if (result.exitCode !== 0)
|
|
451
|
+
throw new Error("\u6D4F\u89C8\u5668\u6309\u9700\u5B89\u88C5\u5931\u8D25: " + result.stderr);
|
|
452
|
+
state = await probe(entry, options, env);
|
|
453
|
+
}
|
|
454
|
+
}
|
|
455
|
+
if (!state.exe)
|
|
456
|
+
throw new Error("\u6267\u884C\u7AEF\u6CA1\u6709\u53EF\u7528\u6D4F\u89C8\u5668: " + (state.failures?.join(" | ") || "\u9884\u88C5\u6D4F\u89C8\u5668\u7F3A\u5931"));
|
|
457
|
+
const packageRoot = path4.dirname(path4.dirname(createRequire(entry).resolve("playwright/package.json")));
|
|
458
|
+
return {
|
|
459
|
+
CRAFT_BROWSER_EXECUTABLE: state.exe,
|
|
460
|
+
UE_CHECK_BROWSER: state.exe,
|
|
461
|
+
PLAYWRIGHT_PACKAGE_ROOT: packageRoot,
|
|
462
|
+
NODE_PATH: [packageRoot, env.NODE_PATH].filter(Boolean).join(path4.delimiter),
|
|
463
|
+
...env.PLAYWRIGHT_BROWSERS_PATH ? { PLAYWRIGHT_BROWSERS_PATH: env.PLAYWRIGHT_BROWSERS_PATH } : {}
|
|
464
|
+
};
|
|
465
|
+
}
|
|
466
|
+
|
|
467
|
+
// vendor/agent-cli/dist/src/component/process-diagnostics.js
|
|
468
|
+
var REASONS = {
|
|
469
|
+
ENOTFOUND: "dns",
|
|
470
|
+
EAI_AGAIN: "dns",
|
|
471
|
+
ECONNREFUSED: "connection_refused",
|
|
472
|
+
ECONNRESET: "connection_reset",
|
|
473
|
+
ETIMEDOUT: "timeout",
|
|
474
|
+
ESOCKETTIMEDOUT: "timeout",
|
|
475
|
+
UND_ERR_CONNECT_TIMEOUT: "timeout",
|
|
476
|
+
CERT_HAS_EXPIRED: "certificate",
|
|
477
|
+
UNABLE_TO_VERIFY_LEAF_SIGNATURE: "certificate",
|
|
478
|
+
DEPTH_ZERO_SELF_SIGNED_CERT: "certificate",
|
|
479
|
+
SELF_SIGNED_CERT_IN_CHAIN: "certificate",
|
|
480
|
+
ENOSPC: "disk_full",
|
|
481
|
+
EDQUOT: "disk_full",
|
|
482
|
+
EACCES: "permission_denied",
|
|
483
|
+
EPERM: "permission_denied",
|
|
484
|
+
ENOENT: "not_found",
|
|
485
|
+
EROFS: "read_only",
|
|
486
|
+
EIO: "io_error",
|
|
487
|
+
EUSAGE: "lockfile_invalid",
|
|
488
|
+
EJSONPARSE: "invalid_manifest",
|
|
489
|
+
ERESOLVE: "dependency_conflict",
|
|
490
|
+
ETARGET: "package_unavailable",
|
|
491
|
+
E404: "package_unavailable",
|
|
492
|
+
E401: "authentication",
|
|
493
|
+
E403: "permission_denied",
|
|
494
|
+
EEXIST: "path_conflict",
|
|
495
|
+
ENOTEMPTY: "path_conflict",
|
|
496
|
+
ENOTDIR: "not_directory",
|
|
497
|
+
EISDIR: "not_directory",
|
|
498
|
+
ELOOP: "symlink_loop",
|
|
499
|
+
EMFILE: "file_limit",
|
|
500
|
+
ENFILE: "file_limit"
|
|
501
|
+
};
|
|
502
|
+
var DiagnosticCause = class extends Error {
|
|
503
|
+
reason;
|
|
504
|
+
fields;
|
|
505
|
+
constructor(reason, fields = {}, cause) {
|
|
506
|
+
super(reason, { cause });
|
|
507
|
+
this.reason = reason;
|
|
508
|
+
this.fields = fields;
|
|
509
|
+
}
|
|
510
|
+
};
|
|
511
|
+
function npmFailureReason(stderr) {
|
|
512
|
+
const codes = [...stderr.matchAll(/^npm (?:ERR!|error) code ([A-Z0-9_]+)\s*$/gm)];
|
|
513
|
+
return REASONS[codes.at(-1)?.[1] ?? ""] ?? "process_exit";
|
|
514
|
+
}
|
|
515
|
+
function validateRegistry(raw) {
|
|
516
|
+
try {
|
|
517
|
+
const url = new URL(raw);
|
|
518
|
+
if (!["http:", "https:"].includes(url.protocol) || url.username || url.password || url.search || url.hash || /[\s\x00-\x1f]/.test(raw))
|
|
519
|
+
throw new Error();
|
|
520
|
+
return url.href;
|
|
521
|
+
} catch {
|
|
522
|
+
throw new DiagnosticCause("invalid_registry");
|
|
523
|
+
}
|
|
524
|
+
}
|
|
525
|
+
|
|
526
|
+
// vendor/agent-cli/dist/src/shared/replace-file.js
|
|
527
|
+
import fs3 from "node:fs/promises";
|
|
528
|
+
import path5 from "node:path";
|
|
529
|
+
import { randomUUID as randomUUID2 } from "node:crypto";
|
|
530
|
+
async function replaceFile(source, target) {
|
|
531
|
+
const previous = process.platform === "win32" ? await fs3.lstat(target).catch((error) => {
|
|
532
|
+
if (error.code === "ENOENT")
|
|
533
|
+
return void 0;
|
|
534
|
+
throw error;
|
|
535
|
+
}) : void 0;
|
|
536
|
+
if (!previous || (previous.mode & 128) !== 0) {
|
|
537
|
+
await fs3.rename(source, target);
|
|
538
|
+
return;
|
|
539
|
+
}
|
|
540
|
+
const pinned = path5.join(path5.dirname(target), `.replace-prior-${randomUUID2()}.tmp`);
|
|
541
|
+
await fs3.link(target, pinned);
|
|
542
|
+
try {
|
|
543
|
+
const opened = await fs3.lstat(pinned);
|
|
544
|
+
if (!opened.isFile() || opened.dev !== previous.dev || opened.ino !== previous.ino)
|
|
545
|
+
throw new Error("Replacement target identity changed");
|
|
546
|
+
await fs3.chmod(pinned, previous.mode | 128);
|
|
547
|
+
try {
|
|
548
|
+
await fs3.rename(source, target);
|
|
549
|
+
} finally {
|
|
550
|
+
await fs3.chmod(pinned, previous.mode);
|
|
551
|
+
}
|
|
552
|
+
} finally {
|
|
553
|
+
await fs3.unlink(pinned);
|
|
554
|
+
}
|
|
555
|
+
}
|
|
556
|
+
|
|
557
|
+
// vendor/agent-cli/dist/src/artifacts/static.js
|
|
558
|
+
import { createHash as createHash2 } from "node:crypto";
|
|
559
|
+
import { constants as constants3 } from "node:fs";
|
|
560
|
+
import { lstat as lstat2, open, readFile as readFile3, readdir as readdir2, realpath as realpath3, stat as stat3, unlink } from "node:fs/promises";
|
|
561
|
+
import path8 from "node:path";
|
|
562
|
+
|
|
563
|
+
// vendor/agent-cli/dist/src/artifacts/preinstalled-dependencies.js
|
|
564
|
+
import { createHash } from "node:crypto";
|
|
565
|
+
import { constants as constants2 } from "node:fs";
|
|
566
|
+
import { chmod, copyFile, link, lstat, mkdir, mkdtemp as mkdtemp2, readFile as readFile2, readdir, readlink, realpath as realpath2, rename, rm as rm2, symlink, writeFile } from "node:fs/promises";
|
|
567
|
+
import path7 from "node:path";
|
|
568
|
+
|
|
569
|
+
// vendor/agent-cli/dist/src/artifacts/dependency-toolchain.js
|
|
570
|
+
import { constants } from "node:fs";
|
|
571
|
+
import { access, readFile, stat as stat2 } from "node:fs/promises";
|
|
572
|
+
import path6 from "node:path";
|
|
573
|
+
var record = (value) => !!value && typeof value === "object" && !Array.isArray(value);
|
|
574
|
+
async function missingDeclaredToolchain(projectDir, manifest) {
|
|
575
|
+
if (!manifest) {
|
|
576
|
+
let data;
|
|
577
|
+
try {
|
|
578
|
+
data = JSON.parse(await readFile(path6.join(projectDir, "package.json"), "utf8"));
|
|
579
|
+
} catch (error) {
|
|
580
|
+
if (error.code === "ENOENT")
|
|
581
|
+
return false;
|
|
582
|
+
throw error;
|
|
583
|
+
}
|
|
584
|
+
if (!record(data))
|
|
585
|
+
return false;
|
|
586
|
+
manifest = data;
|
|
587
|
+
}
|
|
588
|
+
const declared = {
|
|
589
|
+
...record(manifest.dependencies) ? manifest.dependencies : {},
|
|
590
|
+
...record(manifest.devDependencies) ? manifest.devDependencies : {}
|
|
591
|
+
};
|
|
592
|
+
const scripts = record(manifest.scripts) ? Object.values(manifest.scripts).filter((value) => typeof value === "string").join("\n") : "";
|
|
593
|
+
for (const tool of [{ dependency: "typescript", bin: "tsc", script: /\btsc\b/ }, { dependency: "vite", bin: "vite", script: /\bvite\b/ }]) {
|
|
594
|
+
if (typeof declared[tool.dependency] !== "string" || !tool.script.test(scripts))
|
|
595
|
+
continue;
|
|
596
|
+
const executable = path6.join(projectDir, "node_modules", ".bin", tool.bin + (process.platform === "win32" ? ".cmd" : ""));
|
|
597
|
+
try {
|
|
598
|
+
if (!(await stat2(executable)).isFile())
|
|
599
|
+
return true;
|
|
600
|
+
await access(executable, process.platform === "win32" ? constants.F_OK : constants.X_OK);
|
|
601
|
+
} catch (error) {
|
|
602
|
+
if (["ENOENT", "ENOTDIR", "EACCES"].includes(error.code ?? ""))
|
|
603
|
+
return true;
|
|
604
|
+
throw error;
|
|
605
|
+
}
|
|
606
|
+
}
|
|
607
|
+
return false;
|
|
608
|
+
}
|
|
609
|
+
|
|
610
|
+
// vendor/agent-cli/dist/src/artifacts/preinstalled-dependencies.js
|
|
611
|
+
var RECEIPT = ".agent-cli-preinstalled.json";
|
|
612
|
+
var DEPENDENCY_FIELDS = ["dependencies", "devDependencies", "optionalDependencies", "peerDependencies", "peerDependenciesMeta", "overrides"];
|
|
613
|
+
function preinstalledRuntimeIdentity() {
|
|
614
|
+
const header = process.report.getReport().header;
|
|
615
|
+
return {
|
|
616
|
+
platform: process.platform,
|
|
617
|
+
arch: process.arch,
|
|
618
|
+
node: process.versions.node,
|
|
619
|
+
libc: process.platform === "linux" ? header.glibcVersionRuntime ?? "musl" : "none"
|
|
620
|
+
};
|
|
621
|
+
}
|
|
622
|
+
function record2(value) {
|
|
623
|
+
return !!value && typeof value === "object" && !Array.isArray(value);
|
|
624
|
+
}
|
|
625
|
+
function stable(value) {
|
|
626
|
+
if (Array.isArray(value))
|
|
627
|
+
return `[${value.map(stable).join(",")}]`;
|
|
628
|
+
if (record2(value))
|
|
629
|
+
return `{${Object.keys(value).sort().map((key) => `${JSON.stringify(key)}:${stable(value[key])}`).join(",")}}`;
|
|
630
|
+
return JSON.stringify(value);
|
|
631
|
+
}
|
|
632
|
+
function digest(value) {
|
|
633
|
+
return createHash("sha256").update(stable(value)).digest("hex");
|
|
634
|
+
}
|
|
635
|
+
function dependencies(manifest) {
|
|
636
|
+
return Object.fromEntries(DEPENDENCY_FIELDS.filter((key) => record2(manifest[key]) && Object.keys(manifest[key]).length).map((key) => [key, manifest[key]]));
|
|
637
|
+
}
|
|
638
|
+
function coversDependencies(wanted, provided) {
|
|
639
|
+
for (const field of DEPENDENCY_FIELDS) {
|
|
640
|
+
const need = wanted[field];
|
|
641
|
+
if (!record2(need))
|
|
642
|
+
continue;
|
|
643
|
+
const have = provided[field];
|
|
644
|
+
if (!record2(have))
|
|
645
|
+
return false;
|
|
646
|
+
for (const [name, spec] of Object.entries(need))
|
|
647
|
+
if (stable(have[name]) !== stable(spec))
|
|
648
|
+
return false;
|
|
649
|
+
}
|
|
650
|
+
return true;
|
|
651
|
+
}
|
|
652
|
+
function resolveEdge(packages, from, name) {
|
|
653
|
+
for (let base = from; ; ) {
|
|
654
|
+
const location = `${base ? `${base}/` : ""}node_modules/${name}`;
|
|
655
|
+
if (location in packages)
|
|
656
|
+
return location;
|
|
657
|
+
if (!base)
|
|
658
|
+
return void 0;
|
|
659
|
+
const parent = base.lastIndexOf("/node_modules/");
|
|
660
|
+
base = parent < 0 ? "" : base.slice(0, parent);
|
|
661
|
+
}
|
|
662
|
+
}
|
|
663
|
+
function reachablePackages(lock, manifest) {
|
|
664
|
+
const keep = /* @__PURE__ */ new Set();
|
|
665
|
+
const pending = [["", manifest]];
|
|
666
|
+
for (let next = pending.pop(); next; next = pending.pop()) {
|
|
667
|
+
const [from, pkg] = next;
|
|
668
|
+
const fields = from ? ["dependencies", "optionalDependencies", "peerDependencies"] : ["dependencies", "devDependencies", "optionalDependencies", "peerDependencies"];
|
|
669
|
+
for (const field of fields) {
|
|
670
|
+
const edges = pkg[field];
|
|
671
|
+
if (!record2(edges))
|
|
672
|
+
continue;
|
|
673
|
+
for (const name of Object.keys(edges)) {
|
|
674
|
+
const location = resolveEdge(lock.packages, from, name);
|
|
675
|
+
if (!location || keep.has(location))
|
|
676
|
+
continue;
|
|
677
|
+
keep.add(location);
|
|
678
|
+
pending.push([location, lock.packages[location]]);
|
|
679
|
+
}
|
|
680
|
+
}
|
|
681
|
+
}
|
|
682
|
+
return Object.fromEntries(Object.entries(lock.packages).filter(([relative]) => keep.has(relative)));
|
|
683
|
+
}
|
|
684
|
+
function inside(root, target) {
|
|
685
|
+
const relative = path7.relative(root, target);
|
|
686
|
+
return relative === "" || !relative.startsWith(`..${path7.sep}`) && relative !== ".." && !path7.isAbsolute(relative);
|
|
687
|
+
}
|
|
688
|
+
async function jsonFile(file, maxBytes = 8 * 1024 * 1024) {
|
|
689
|
+
const info = await lstat(file);
|
|
690
|
+
if (!info.isFile() || info.size > maxBytes)
|
|
691
|
+
throw new DiagnosticCause("preinstalled_invalid");
|
|
692
|
+
const value = JSON.parse(await readFile2(file, "utf8"));
|
|
693
|
+
if (!record2(value))
|
|
694
|
+
throw new DiagnosticCause("preinstalled_invalid");
|
|
695
|
+
return value;
|
|
696
|
+
}
|
|
697
|
+
function asLock(value) {
|
|
698
|
+
if (value.lockfileVersion !== 3 || !record2(value.packages) || !record2(value.packages[""]))
|
|
699
|
+
throw new DiagnosticCause("preinstalled_invalid");
|
|
700
|
+
return value;
|
|
701
|
+
}
|
|
702
|
+
var METADATA_FIELDS = ["license", "funding", "deprecated"];
|
|
703
|
+
var IDENTITY_VERSION = 2;
|
|
704
|
+
var PUBLIC_REGISTRY = "https://registry.npmjs.org/";
|
|
705
|
+
function packageName(relative, pkg) {
|
|
706
|
+
return typeof pkg.name === "string" ? pkg.name : relative.slice(relative.lastIndexOf("node_modules/") + "node_modules/".length);
|
|
707
|
+
}
|
|
708
|
+
function registryTarballBase(relative, pkg) {
|
|
709
|
+
if (typeof pkg.resolved !== "string" || typeof pkg.version !== "string" || typeof pkg.integrity !== "string" || !/^sha512-[A-Za-z0-9+/]{86}==$/.test(pkg.integrity))
|
|
710
|
+
return void 0;
|
|
711
|
+
let url;
|
|
712
|
+
try {
|
|
713
|
+
url = new URL(pkg.resolved);
|
|
714
|
+
} catch {
|
|
715
|
+
return void 0;
|
|
716
|
+
}
|
|
717
|
+
if (url.protocol !== "https:" || url.username || url.password || url.search || url.hash)
|
|
718
|
+
return void 0;
|
|
719
|
+
const name = packageName(relative, pkg);
|
|
720
|
+
const suffix = `/${name}/-/${name.slice(name.lastIndexOf("/") + 1)}-${pkg.version}.tgz`;
|
|
721
|
+
if (!url.pathname.endsWith(suffix) || url.href !== pkg.resolved)
|
|
722
|
+
return void 0;
|
|
723
|
+
return `${url.origin}${url.pathname.slice(0, -suffix.length)}/`;
|
|
724
|
+
}
|
|
725
|
+
function lockIdentity(lock) {
|
|
726
|
+
const peerTargets = /* @__PURE__ */ new Set();
|
|
727
|
+
for (const pkg of Object.values(lock.packages)) {
|
|
728
|
+
if (record2(pkg) && record2(pkg.peerDependencies))
|
|
729
|
+
for (const name of Object.keys(pkg.peerDependencies))
|
|
730
|
+
peerTargets.add(name);
|
|
731
|
+
}
|
|
732
|
+
const packages = { "": dependencies(lock.packages[""]) };
|
|
733
|
+
for (const [relative, pkg] of Object.entries(lock.packages)) {
|
|
734
|
+
if (!relative)
|
|
735
|
+
continue;
|
|
736
|
+
if (!record2(pkg)) {
|
|
737
|
+
packages[relative] = pkg;
|
|
738
|
+
continue;
|
|
739
|
+
}
|
|
740
|
+
const normalized = { ...pkg };
|
|
741
|
+
for (const field of METADATA_FIELDS)
|
|
742
|
+
delete normalized[field];
|
|
743
|
+
if (registryTarballBase(relative, pkg))
|
|
744
|
+
normalized.resolved = "registry-tarball";
|
|
745
|
+
if (normalized.peer === true && peerTargets.has(packageName(relative, pkg)))
|
|
746
|
+
delete normalized.peer;
|
|
747
|
+
packages[relative] = normalized;
|
|
748
|
+
}
|
|
749
|
+
return packages;
|
|
750
|
+
}
|
|
751
|
+
function lockCovers(projectLock, bundleLock) {
|
|
752
|
+
if (untrustedRegistry(projectLock, bundleLock))
|
|
753
|
+
return false;
|
|
754
|
+
const bundleId = lockIdentity(bundleLock);
|
|
755
|
+
for (const [relative, pkg] of Object.entries(lockIdentity(projectLock))) {
|
|
756
|
+
if (!relative)
|
|
757
|
+
continue;
|
|
758
|
+
if (stable(bundleId[relative]) !== stable(pkg))
|
|
759
|
+
return false;
|
|
760
|
+
}
|
|
761
|
+
return coversDependencies(dependencies(projectLock.packages[""]), dependencies(bundleLock.packages[""]));
|
|
762
|
+
}
|
|
763
|
+
function untrustedRegistry(projectLock, bundleLock) {
|
|
764
|
+
const trusted = /* @__PURE__ */ new Set([PUBLIC_REGISTRY]);
|
|
765
|
+
try {
|
|
766
|
+
if (process.env.CRAFT_NPM_REGISTRY)
|
|
767
|
+
trusted.add(new URL(validateRegistry(process.env.CRAFT_NPM_REGISTRY)).href.replace(/\/?$/, "/"));
|
|
768
|
+
} catch {
|
|
769
|
+
}
|
|
770
|
+
for (const [relative, pkg] of Object.entries(bundleLock.packages)) {
|
|
771
|
+
const base = relative && record2(pkg) ? registryTarballBase(relative, pkg) : void 0;
|
|
772
|
+
if (base)
|
|
773
|
+
trusted.add(base);
|
|
774
|
+
}
|
|
775
|
+
return Object.entries(projectLock.packages).some(([relative, pkg]) => {
|
|
776
|
+
if (!relative || !record2(pkg) || pkg.resolved === bundleLock.packages[relative]?.resolved)
|
|
777
|
+
return false;
|
|
778
|
+
const base = registryTarballBase(relative, pkg);
|
|
779
|
+
return !base || !trusted.has(base);
|
|
780
|
+
});
|
|
781
|
+
}
|
|
782
|
+
async function matchBundle(root, cwd, manifest, hasLock, signal) {
|
|
783
|
+
const miss = (reason) => ({ source: "registry", reason });
|
|
784
|
+
if (!root)
|
|
785
|
+
return miss("preinstalled_unavailable");
|
|
786
|
+
if (!path7.isAbsolute(root))
|
|
787
|
+
return miss("preinstalled_invalid");
|
|
788
|
+
try {
|
|
789
|
+
root = await realpath2(root);
|
|
790
|
+
if (inside(cwd, root) || inside(root, cwd))
|
|
791
|
+
return miss("preinstalled_invalid");
|
|
792
|
+
const runtime = await jsonFile(path7.join(root, "runtime.json"), 4096);
|
|
793
|
+
if (Object.entries(preinstalledRuntimeIdentity()).some(([key, value]) => runtime[key] !== value))
|
|
794
|
+
return miss("preinstalled_mismatch");
|
|
795
|
+
if (manifest.workspaces || manifest.bundleDependencies || manifest.bundledDependencies)
|
|
796
|
+
return miss("preinstalled_mismatch");
|
|
797
|
+
const projectLock = hasLock ? asLock(await jsonFile(path7.join(cwd, "package-lock.json"))) : void 0;
|
|
798
|
+
const entries = await readdir(root, { withFileTypes: true });
|
|
799
|
+
if (entries.length > 32)
|
|
800
|
+
return miss("preinstalled_invalid");
|
|
801
|
+
for (const entry of entries.sort((a, b) => a.name.localeCompare(b.name))) {
|
|
802
|
+
signal?.throwIfAborted();
|
|
803
|
+
if (!entry.isDirectory())
|
|
804
|
+
continue;
|
|
805
|
+
const bundle = path7.join(root, entry.name);
|
|
806
|
+
const candidate = await jsonFile(path7.join(bundle, "package.json"));
|
|
807
|
+
const candidateDeps = dependencies(candidate);
|
|
808
|
+
if (!coversDependencies(dependencies(manifest), candidateDeps))
|
|
809
|
+
continue;
|
|
810
|
+
const lock = asLock(await jsonFile(path7.join(bundle, "package-lock.json")));
|
|
811
|
+
if (stable(dependencies(lock.packages[""])) !== stable(candidateDeps))
|
|
812
|
+
return miss("preinstalled_invalid");
|
|
813
|
+
if (projectLock && !lockCovers(projectLock, lock))
|
|
814
|
+
continue;
|
|
815
|
+
const modules = path7.join(bundle, "node_modules");
|
|
816
|
+
if (!(await lstat(modules)).isDirectory() || await missingDeclaredToolchain(bundle, manifest))
|
|
817
|
+
return miss("preinstalled_invalid");
|
|
818
|
+
for (const [relative, pkg] of Object.entries(lock.packages)) {
|
|
819
|
+
signal?.throwIfAborted();
|
|
820
|
+
if (!relative)
|
|
821
|
+
continue;
|
|
822
|
+
if (!record2(pkg) || !relative.startsWith("node_modules/") || relative.includes("\\") || !inside(modules, path7.resolve(bundle, relative)))
|
|
823
|
+
return miss("preinstalled_invalid");
|
|
824
|
+
try {
|
|
825
|
+
const installed = await jsonFile(path7.join(bundle, relative, "package.json"));
|
|
826
|
+
if (installed.version !== pkg.version)
|
|
827
|
+
return miss("preinstalled_invalid");
|
|
828
|
+
} catch (error) {
|
|
829
|
+
if (pkg.optional === true && error.code === "ENOENT")
|
|
830
|
+
continue;
|
|
831
|
+
return miss("preinstalled_invalid");
|
|
832
|
+
}
|
|
833
|
+
}
|
|
834
|
+
return { modules, lock, projectLock };
|
|
835
|
+
}
|
|
836
|
+
return miss("preinstalled_mismatch");
|
|
837
|
+
} catch (error) {
|
|
838
|
+
signal?.throwIfAborted();
|
|
839
|
+
return miss(error.code === "ENOENT" ? "preinstalled_unavailable" : "preinstalled_invalid");
|
|
840
|
+
}
|
|
841
|
+
}
|
|
842
|
+
async function copyTree(source, destination, root, signal) {
|
|
843
|
+
signal?.throwIfAborted();
|
|
844
|
+
const info = await lstat(source);
|
|
845
|
+
if (info.isSymbolicLink()) {
|
|
846
|
+
const target = await readlink(source);
|
|
847
|
+
if (path7.isAbsolute(target) || !inside(root, path7.resolve(path7.dirname(source), target)) || !inside(root, await realpath2(source)))
|
|
848
|
+
throw new DiagnosticCause("preinstalled_invalid");
|
|
849
|
+
await symlink(target, destination);
|
|
850
|
+
} else if (info.isDirectory()) {
|
|
851
|
+
await mkdir(destination, { mode: 448 });
|
|
852
|
+
for (const name of await readdir(source)) {
|
|
853
|
+
if (name === RECEIPT || name === ".package-lock.json")
|
|
854
|
+
continue;
|
|
855
|
+
await copyTree(path7.join(source, name), path7.join(destination, name), root, signal);
|
|
856
|
+
}
|
|
857
|
+
} else if (info.isFile()) {
|
|
858
|
+
await copyFile(source, destination, constants2.COPYFILE_FICLONE);
|
|
859
|
+
await chmod(destination, info.mode & 511 | 384);
|
|
860
|
+
} else
|
|
861
|
+
throw new DiagnosticCause("preinstalled_invalid");
|
|
862
|
+
}
|
|
863
|
+
async function restorePreinstalledDependencies(cwd, manifest, hasLock, signal, report) {
|
|
864
|
+
const bundle = await matchBundle(process.env.CRAFT_JS_DEPENDENCIES_DIR ?? "", cwd, manifest, hasLock, signal);
|
|
865
|
+
if ("source" in bundle) {
|
|
866
|
+
report?.(bundle);
|
|
867
|
+
return false;
|
|
868
|
+
}
|
|
869
|
+
report?.({ source: "preinstalled", reason: "preinstalled_hit" });
|
|
870
|
+
signal?.throwIfAborted();
|
|
871
|
+
const staging = await mkdtemp2(path7.join(cwd, ".agent-cli-dependencies-"));
|
|
872
|
+
const modules = path7.join(cwd, "node_modules");
|
|
873
|
+
const replacement = path7.join(staging, "node_modules");
|
|
874
|
+
const previous = path7.join(staging, "previous");
|
|
875
|
+
try {
|
|
876
|
+
try {
|
|
877
|
+
await copyTree(bundle.modules, replacement, bundle.modules, signal);
|
|
878
|
+
} catch (error) {
|
|
879
|
+
if (error instanceof DiagnosticCause && error.reason === "preinstalled_invalid") {
|
|
880
|
+
report?.({ source: "registry", reason: "preinstalled_invalid" });
|
|
881
|
+
return false;
|
|
882
|
+
}
|
|
883
|
+
throw error;
|
|
884
|
+
}
|
|
885
|
+
signal?.throwIfAborted();
|
|
886
|
+
const lock = { ...bundle.lock, packages: { "": { ...dependencies(manifest) }, ...reachablePackages(bundle.lock, manifest) } };
|
|
887
|
+
for (const key of ["name", "version"]) {
|
|
888
|
+
delete lock[key];
|
|
889
|
+
if (typeof manifest[key] === "string")
|
|
890
|
+
lock[key] = lock.packages[""][key] = manifest[key];
|
|
891
|
+
}
|
|
892
|
+
await writeFile(path7.join(replacement, RECEIPT), JSON.stringify({
|
|
893
|
+
identity: IDENTITY_VERSION,
|
|
894
|
+
manifest: digest(dependencies(manifest)),
|
|
895
|
+
lock: digest(lockIdentity(bundle.projectLock ?? lock))
|
|
896
|
+
}), { mode: 384 });
|
|
897
|
+
if (!hasLock) {
|
|
898
|
+
const stagedLock = path7.join(staging, "package-lock.json");
|
|
899
|
+
await writeFile(stagedLock, JSON.stringify(lock, null, 2) + "\n", { flag: "wx", mode: 384 });
|
|
900
|
+
await link(stagedLock, path7.join(cwd, "package-lock.json"));
|
|
901
|
+
}
|
|
902
|
+
signal?.throwIfAborted();
|
|
903
|
+
let moved = false;
|
|
904
|
+
try {
|
|
905
|
+
await rename(modules, previous);
|
|
906
|
+
moved = true;
|
|
907
|
+
} catch (error) {
|
|
908
|
+
if (error.code !== "ENOENT")
|
|
909
|
+
throw error;
|
|
910
|
+
}
|
|
911
|
+
try {
|
|
912
|
+
await rename(replacement, modules);
|
|
913
|
+
} catch (error) {
|
|
914
|
+
if (moved)
|
|
915
|
+
await rename(previous, modules);
|
|
916
|
+
throw error;
|
|
917
|
+
}
|
|
918
|
+
return true;
|
|
919
|
+
} finally {
|
|
920
|
+
await rm2(staging, { recursive: true, force: true });
|
|
921
|
+
}
|
|
922
|
+
}
|
|
923
|
+
|
|
924
|
+
// vendor/agent-cli/dist/src/artifacts/build-failure.js
|
|
925
|
+
import { stripVTControlCharacters } from "node:util";
|
|
926
|
+
var BuildFailureError = class extends Error {
|
|
927
|
+
constructor(message, options) {
|
|
928
|
+
super(boundBuildDiagnostic(message), options);
|
|
929
|
+
}
|
|
930
|
+
};
|
|
931
|
+
function boundBuildDiagnostic(message) {
|
|
932
|
+
const clean = stripVTControlCharacters(message).replace(/[\x00-\x08\x0b-\x1f\x7f-\x9f]/g, "").trim();
|
|
933
|
+
let result = "";
|
|
934
|
+
let bytes = 0;
|
|
935
|
+
for (const char of clean) {
|
|
936
|
+
bytes += Buffer.byteLength(char);
|
|
937
|
+
if (bytes > 4e3)
|
|
938
|
+
break;
|
|
939
|
+
result += char;
|
|
940
|
+
}
|
|
941
|
+
return result;
|
|
942
|
+
}
|
|
943
|
+
function buildFailureExcerpt(stdout, stderr) {
|
|
944
|
+
const lines = stripVTControlCharacters(`${stdout}
|
|
945
|
+
${stderr}`).split(/\r?\n/).map((line) => line.trim()).filter(Boolean);
|
|
946
|
+
const picked = lines.filter((line) => /\berror TS\d+\b/.test(line) || /(?:tsc|vite): (?:not found|Permission denied)/.test(line) || /Could not resolve|Could not load|Cannot find module|Module not found/.test(line) || /^(?:Error:|error during build:|\[vite[^\]]*\])/.test(line) || /Found \d+ error/.test(line));
|
|
947
|
+
if (picked.length)
|
|
948
|
+
return boundBuildDiagnostic(picked.slice(0, 12).join("\n"));
|
|
949
|
+
const useful = lines.filter((line) => !/^npm notice\b/.test(line) && !/^\[export-config\].*\bslots=/.test(line));
|
|
950
|
+
return boundBuildDiagnostic((useful.length ? useful : lines).slice(-12).join("\n"));
|
|
951
|
+
}
|
|
952
|
+
|
|
953
|
+
// vendor/agent-cli/dist/src/artifacts/static.js
|
|
954
|
+
var PROJECT_INSTALL_TIMEOUT_MS = 6e5;
|
|
955
|
+
var INSTALL_PENDING = ".agent-cli-dependencies-pending";
|
|
956
|
+
async function installProjectDependencies(projectDir, runner = runNpmInstall, signal, timeoutMs = PROJECT_INSTALL_TIMEOUT_MS, report) {
|
|
957
|
+
signal?.throwIfAborted();
|
|
958
|
+
const context = await dependencyInstallContext(projectDir);
|
|
959
|
+
if (!context.hasDependencies)
|
|
960
|
+
return;
|
|
961
|
+
const args = context.hasLock ? ["ci", "--ignore-scripts", "--include=dev", "--no-audit", "--no-fund"] : ["install", "--ignore-scripts", "--include=dev", "--no-audit", "--no-fund", "--package-lock=true"];
|
|
962
|
+
signal?.throwIfAborted();
|
|
963
|
+
const markerPath = path8.join(context.cwd, INSTALL_PENDING);
|
|
964
|
+
await markDependencyInstall(markerPath);
|
|
965
|
+
const started = Date.now();
|
|
966
|
+
const budget = AbortSignal.timeout(timeoutMs);
|
|
967
|
+
const copySignal = signal ? AbortSignal.any([signal, budget]) : budget;
|
|
968
|
+
let reused;
|
|
969
|
+
try {
|
|
970
|
+
reused = await restorePreinstalledDependencies(context.cwd, context.manifest, context.hasLock, copySignal, report);
|
|
971
|
+
} catch (error) {
|
|
972
|
+
signal?.throwIfAborted();
|
|
973
|
+
if (budget.aborted)
|
|
974
|
+
throw new LinkError(ErrDependencyInstallTimeout, new DiagnosticCause("timeout", { timeout_ms: timeoutMs, timed_out: true }));
|
|
975
|
+
throw new LinkError(ErrDependencyInstallFailed, error);
|
|
976
|
+
}
|
|
977
|
+
if (!reused) {
|
|
978
|
+
const remaining = timeoutMs - (Date.now() - started);
|
|
979
|
+
if (remaining <= 0)
|
|
980
|
+
throw new LinkError(ErrDependencyInstallTimeout, new DiagnosticCause("timeout", { timeout_ms: timeoutMs, timed_out: true }));
|
|
981
|
+
const env = installEnvironment(true);
|
|
982
|
+
if (env.CRAFT_NPM_REGISTRY)
|
|
983
|
+
args.push("--registry", env.CRAFT_NPM_REGISTRY);
|
|
984
|
+
await runner(context.cwd, args, env, remaining, signal);
|
|
985
|
+
signal?.throwIfAborted();
|
|
986
|
+
if (await missingDeclaredToolchain(context.cwd))
|
|
987
|
+
throw new LinkError(ErrDependencyInstallFailed, new DiagnosticCause("toolchain_missing"));
|
|
988
|
+
}
|
|
989
|
+
signal?.throwIfAborted();
|
|
990
|
+
await unlink(markerPath);
|
|
991
|
+
}
|
|
992
|
+
async function markDependencyInstall(markerPath) {
|
|
993
|
+
try {
|
|
994
|
+
const marker = await open(markerPath, constants3.O_WRONLY | constants3.O_CREAT | constants3.O_EXCL, 384);
|
|
995
|
+
await marker.close();
|
|
996
|
+
} catch (error) {
|
|
997
|
+
if (error.code !== "EEXIST")
|
|
998
|
+
throw error;
|
|
999
|
+
const existing = await lstat2(markerPath);
|
|
1000
|
+
if (!existing.isFile() || existing.isSymbolicLink())
|
|
1001
|
+
throw new Error("dependency preparation marker must be a regular file");
|
|
1002
|
+
}
|
|
1003
|
+
}
|
|
1004
|
+
async function dependencyInstallContext(projectDir) {
|
|
1005
|
+
if (!path8.isAbsolute(projectDir))
|
|
1006
|
+
throw new Error("snapshot project directory must be absolute");
|
|
1007
|
+
const cwd = await realpath3(projectDir);
|
|
1008
|
+
if (!(await stat3(cwd)).isDirectory())
|
|
1009
|
+
throw new Error("snapshot project is not a directory");
|
|
1010
|
+
let packageData;
|
|
1011
|
+
try {
|
|
1012
|
+
packageData = JSON.parse(await readFile3(path8.join(cwd, "package.json"), "utf8"));
|
|
1013
|
+
} catch (error) {
|
|
1014
|
+
if (error.code === "ENOENT")
|
|
1015
|
+
return { cwd, manifest: {}, hasDependencies: false, hasLock: false };
|
|
1016
|
+
throw new DiagnosticCause("invalid_manifest", {}, error);
|
|
1017
|
+
}
|
|
1018
|
+
if (!isRecord(packageData))
|
|
1019
|
+
throw new Error("snapshot package.json is invalid");
|
|
1020
|
+
const manifest = packageData;
|
|
1021
|
+
const hasDependencies = ["dependencies", "devDependencies", "optionalDependencies"].some((key) => {
|
|
1022
|
+
const value = packageData[key];
|
|
1023
|
+
return isRecord(value) && Object.keys(value).length > 0;
|
|
1024
|
+
});
|
|
1025
|
+
if (!hasDependencies)
|
|
1026
|
+
return { cwd, manifest, hasDependencies: false, hasLock: false };
|
|
1027
|
+
try {
|
|
1028
|
+
const lock = await lstat2(path8.join(cwd, "package-lock.json"));
|
|
1029
|
+
if (!lock.isFile() || lock.isSymbolicLink())
|
|
1030
|
+
throw new Error("package-lock.json must be a regular file");
|
|
1031
|
+
return { cwd, manifest, hasDependencies, hasLock: true };
|
|
1032
|
+
} catch (error) {
|
|
1033
|
+
if (error.code === "ENOENT")
|
|
1034
|
+
return { cwd, manifest, hasDependencies, hasLock: false };
|
|
1035
|
+
throw error;
|
|
1036
|
+
}
|
|
1037
|
+
}
|
|
1038
|
+
function installEnvironment(install = false) {
|
|
1039
|
+
const env = {
|
|
1040
|
+
PATH: process.env.PATH ?? "",
|
|
1041
|
+
HOME: process.env.HOME ?? "",
|
|
1042
|
+
NODE_ENV: "production"
|
|
1043
|
+
};
|
|
1044
|
+
if (install && process.env.CRAFT_NPM_REGISTRY)
|
|
1045
|
+
env.CRAFT_NPM_REGISTRY = validateRegistry(process.env.CRAFT_NPM_REGISTRY);
|
|
1046
|
+
if (process.platform === "win32") {
|
|
1047
|
+
for (const key of ["SystemRoot", "WINDIR", "ComSpec", "PATHEXT", "TEMP", "TMP"]) {
|
|
1048
|
+
if (process.env[key])
|
|
1049
|
+
env[key] = process.env[key];
|
|
1050
|
+
}
|
|
1051
|
+
}
|
|
1052
|
+
return env;
|
|
1053
|
+
}
|
|
1054
|
+
async function buildJsStatic(projectDir, timeoutMs = 12e4, environment = {}, signal) {
|
|
1055
|
+
if (!path8.isAbsolute(projectDir) || timeoutMs < 1e3 || timeoutMs > 3e5)
|
|
1056
|
+
throw new Error("invalid JS build input", { cause: new DiagnosticCause("build_input_invalid") });
|
|
1057
|
+
const cwd = await realpath3(projectDir);
|
|
1058
|
+
if (!(await stat3(cwd)).isDirectory())
|
|
1059
|
+
throw new Error("JS project is not a directory", { cause: new DiagnosticCause("build_input_invalid") });
|
|
1060
|
+
const env = installEnvironment();
|
|
1061
|
+
for (const key of ["CLAUDE_DIR", "CLAUDE_PROJECT_DIR"]) {
|
|
1062
|
+
if (environment[key])
|
|
1063
|
+
env[key] = environment[key];
|
|
1064
|
+
}
|
|
1065
|
+
const npm = resolveProgram("npm", ["run", "build"], env);
|
|
1066
|
+
signal?.throwIfAborted();
|
|
1067
|
+
const result = await runProcess(npm.file, npm.args, { cwd, env, timeoutMs, signal, readOnlyDirectories: environment.CLAUDE_DIR ? [environment.CLAUDE_DIR] : [] });
|
|
1068
|
+
signal?.throwIfAborted();
|
|
1069
|
+
const details = { exit_code: result.exitCode, signal: result.signal, timed_out: result.timedOut, aborted: result.aborted, timeout_ms: timeoutMs };
|
|
1070
|
+
if (result.timedOut)
|
|
1071
|
+
throw new BuildFailureError("JS build timed out", { cause: new DiagnosticCause("timeout", details) });
|
|
1072
|
+
if (result.exitCode !== 0)
|
|
1073
|
+
throw new BuildFailureError(`JS build failed (exit ${result.exitCode}): ${buildFailureExcerpt(result.stdout, result.stderr)}`, { cause: new DiagnosticCause(result.signal ? "process_signal" : npmFailureReason(result.stderr), details) });
|
|
1074
|
+
}
|
|
1075
|
+
async function runNpmInstall(cwd, args, env, timeoutMs, signal) {
|
|
1076
|
+
const npm = resolveProgram("npm", args, env);
|
|
1077
|
+
const result = await runProcess(npm.file, npm.args, { cwd, env, timeoutMs, signal, trustedNetwork: true });
|
|
1078
|
+
const details = { exit_code: result.exitCode, signal: result.signal, timed_out: result.timedOut, aborted: result.aborted, timeout_ms: timeoutMs };
|
|
1079
|
+
if (signal?.aborted)
|
|
1080
|
+
throw new DiagnosticCause("cancelled", details, signal.reason);
|
|
1081
|
+
if (result.timedOut)
|
|
1082
|
+
throw new LinkError(ErrDependencyInstallTimeout, new DiagnosticCause("timeout", details));
|
|
1083
|
+
if (result.exitCode !== 0)
|
|
1084
|
+
throw new LinkError(ErrDependencyInstallFailed, new DiagnosticCause(result.signal ? "process_signal" : npmFailureReason(result.stderr), details));
|
|
1085
|
+
}
|
|
1086
|
+
function isRecord(value) {
|
|
1087
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
1088
|
+
}
|
|
1089
|
+
async function prepareStaticArtifacts(distDir) {
|
|
1090
|
+
if (!path8.isAbsolute(distDir))
|
|
1091
|
+
throw new Error("static directory must be absolute", { cause: new DiagnosticCause("static_output_invalid") });
|
|
1092
|
+
try {
|
|
1093
|
+
if ((await lstat2(distDir)).isSymbolicLink())
|
|
1094
|
+
throw new Error("static directory must not be a symlink", { cause: new DiagnosticCause("static_output_invalid") });
|
|
1095
|
+
} catch (error) {
|
|
1096
|
+
if (error.code === "ENOENT")
|
|
1097
|
+
throw new BuildFailureError("JS build produced no dist output", { cause: new DiagnosticCause("static_output_missing") });
|
|
1098
|
+
throw error;
|
|
1099
|
+
}
|
|
1100
|
+
const root = await realpath3(distDir);
|
|
1101
|
+
if (!(await stat3(root)).isDirectory())
|
|
1102
|
+
throw new Error("static output is not a directory", { cause: new DiagnosticCause("static_output_invalid") });
|
|
1103
|
+
const artifacts = [];
|
|
1104
|
+
let totalBytes = 0;
|
|
1105
|
+
async function walk(dir) {
|
|
1106
|
+
const entries = await readdir2(dir, { withFileTypes: true });
|
|
1107
|
+
entries.sort((a, b) => a.name.localeCompare(b.name));
|
|
1108
|
+
for (const entry of entries) {
|
|
1109
|
+
if (entry.name.startsWith(".") || /(?:secret|credential|token|private[_-]?key)/i.test(entry.name))
|
|
1110
|
+
continue;
|
|
1111
|
+
const absolute = path8.join(dir, entry.name);
|
|
1112
|
+
if (entry.isDirectory()) {
|
|
1113
|
+
await walk(absolute);
|
|
1114
|
+
continue;
|
|
1115
|
+
}
|
|
1116
|
+
if (!entry.isFile())
|
|
1117
|
+
continue;
|
|
1118
|
+
if (artifacts.length >= 2e3)
|
|
1119
|
+
throw new Error("static file count exceeds limit", { cause: new DiagnosticCause("static_limit_exceeded") });
|
|
1120
|
+
const handle = await open(absolute, constants3.O_RDONLY | (constants3.O_NOFOLLOW ?? 0));
|
|
1121
|
+
try {
|
|
1122
|
+
const info = await handle.stat();
|
|
1123
|
+
if (!info.isFile() || info.size > 8 * 1024 * 1024 || totalBytes + info.size > 64 * 1024 * 1024) {
|
|
1124
|
+
throw new Error("static file exceeds size limit", { cause: new DiagnosticCause("static_limit_exceeded") });
|
|
1125
|
+
}
|
|
1126
|
+
const content = await handle.readFile();
|
|
1127
|
+
if (content.length !== info.size)
|
|
1128
|
+
throw new Error("static file changed during collection", { cause: new DiagnosticCause("artifact_changed") });
|
|
1129
|
+
totalBytes += content.length;
|
|
1130
|
+
artifacts.push({
|
|
1131
|
+
relativePath: path8.relative(root, absolute).split(path8.sep).join("/"),
|
|
1132
|
+
path: absolute,
|
|
1133
|
+
bytes: content.length,
|
|
1134
|
+
sha256: createHash2("sha256").update(content).digest("hex")
|
|
1135
|
+
});
|
|
1136
|
+
} finally {
|
|
1137
|
+
await handle.close();
|
|
1138
|
+
}
|
|
1139
|
+
}
|
|
1140
|
+
}
|
|
1141
|
+
await walk(root);
|
|
1142
|
+
if (!artifacts.some((item) => item.relativePath === "index.html"))
|
|
1143
|
+
throw new BuildFailureError("JS build has no index.html", { cause: new DiagnosticCause("static_output_missing") });
|
|
1144
|
+
return artifacts;
|
|
1145
|
+
}
|
|
1146
|
+
|
|
1147
|
+
// vendor/agent-cli/dist/src/artifacts/external-game-archive.js
|
|
1148
|
+
import { createHash as createHash3 } from "node:crypto";
|
|
1149
|
+
var EXTERNAL_GAME_UPLOAD_LIMITS = Object.freeze({
|
|
1150
|
+
files: 2e3,
|
|
1151
|
+
fileBytes: 8 * 1024 * 1024,
|
|
1152
|
+
totalFileBytes: 64 * 1024 * 1024,
|
|
1153
|
+
archiveBytes: 65 * 1024 * 1024,
|
|
1154
|
+
gzipBytes: 66 * 1024 * 1024,
|
|
1155
|
+
jsonBytes: 90 * 1024 * 1024,
|
|
1156
|
+
pathBytes: 240,
|
|
1157
|
+
centralDirectoryBytes: 4 * 1024 * 1024
|
|
1158
|
+
});
|
|
1159
|
+
var crcTable = Uint32Array.from({ length: 256 }, (_, value) => {
|
|
1160
|
+
for (let bit = 0; bit < 8; bit++)
|
|
1161
|
+
value = value & 1 ? value >>> 1 ^ 3988292384 : value >>> 1;
|
|
1162
|
+
return value >>> 0;
|
|
1163
|
+
});
|
|
1164
|
+
function crc32(data) {
|
|
1165
|
+
let value = 4294967295;
|
|
1166
|
+
for (const byte of data)
|
|
1167
|
+
value = crcTable[(value ^ byte) & 255] ^ value >>> 8;
|
|
1168
|
+
return (value ^ 4294967295) >>> 0;
|
|
1169
|
+
}
|
|
1170
|
+
function checkedName(name) {
|
|
1171
|
+
if (typeof name !== "string" || !name || name.normalize("NFC") !== name || /[\p{Cc}\\:%?#<>|"*]/u.test(name) || name.split("/").some((part) => !part || part.startsWith(".") || part.endsWith(".") || part.endsWith(" "))) {
|
|
1172
|
+
throw new Error("Invalid external game archive file path");
|
|
1173
|
+
}
|
|
1174
|
+
const encoded = Buffer.from(name, "utf8");
|
|
1175
|
+
if (encoded.length > EXTERNAL_GAME_UPLOAD_LIMITS.pathBytes || encoded.toString("utf8") !== name) {
|
|
1176
|
+
throw new Error("External game archive file path exceeds the platform limit or contains invalid Unicode");
|
|
1177
|
+
}
|
|
1178
|
+
return encoded;
|
|
1179
|
+
}
|
|
1180
|
+
function collisionKey(name) {
|
|
1181
|
+
return name.toUpperCase().toLowerCase().normalize("NFC");
|
|
1182
|
+
}
|
|
1183
|
+
function encodeExternalGameArchive(files, signal) {
|
|
1184
|
+
signal?.throwIfAborted();
|
|
1185
|
+
const parts = [], central = [], names = /* @__PURE__ */ new Set();
|
|
1186
|
+
let offset = 0, centralBytes = 0, totalBytes = 0;
|
|
1187
|
+
let hasEntryPoint = false;
|
|
1188
|
+
for (const [name, input] of files) {
|
|
1189
|
+
signal?.throwIfAborted();
|
|
1190
|
+
const encoded = checkedName(name), key = collisionKey(name);
|
|
1191
|
+
if (names.size >= EXTERNAL_GAME_UPLOAD_LIMITS.files)
|
|
1192
|
+
throw new Error("External game archive file count exceeds the platform limit");
|
|
1193
|
+
if (names.has(key))
|
|
1194
|
+
throw new Error("External game archive contains duplicate file paths");
|
|
1195
|
+
if (!(input instanceof Uint8Array) || input.byteLength > EXTERNAL_GAME_UPLOAD_LIMITS.fileBytes || totalBytes + input.byteLength > EXTERNAL_GAME_UPLOAD_LIMITS.totalFileBytes) {
|
|
1196
|
+
throw new Error("External game archive file bytes exceed the platform limit");
|
|
1197
|
+
}
|
|
1198
|
+
names.add(key);
|
|
1199
|
+
totalBytes += input.byteLength;
|
|
1200
|
+
hasEntryPoint ||= name === "index.html" && input.byteLength > 0;
|
|
1201
|
+
const data = Buffer.from(input);
|
|
1202
|
+
const checksum = crc32(data);
|
|
1203
|
+
const local = Buffer.alloc(30);
|
|
1204
|
+
local.writeUInt32LE(67324752, 0);
|
|
1205
|
+
local.writeUInt16LE(20, 4);
|
|
1206
|
+
local.writeUInt16LE(2048, 6);
|
|
1207
|
+
local.writeUInt16LE(33, 12);
|
|
1208
|
+
local.writeUInt32LE(checksum, 14);
|
|
1209
|
+
local.writeUInt32LE(data.length, 18);
|
|
1210
|
+
local.writeUInt32LE(data.length, 22);
|
|
1211
|
+
local.writeUInt16LE(encoded.length, 26);
|
|
1212
|
+
const entry = Buffer.alloc(46);
|
|
1213
|
+
entry.writeUInt32LE(33639248, 0);
|
|
1214
|
+
entry.writeUInt16LE(20, 4);
|
|
1215
|
+
local.copy(entry, 6, 4, 30);
|
|
1216
|
+
entry.writeUInt32LE(offset, 42);
|
|
1217
|
+
parts.push(local, encoded, data);
|
|
1218
|
+
central.push(entry, encoded);
|
|
1219
|
+
offset += local.length + encoded.length + data.length;
|
|
1220
|
+
centralBytes += entry.length + encoded.length;
|
|
1221
|
+
if (centralBytes > EXTERNAL_GAME_UPLOAD_LIMITS.centralDirectoryBytes || offset + centralBytes + 22 > EXTERNAL_GAME_UPLOAD_LIMITS.archiveBytes) {
|
|
1222
|
+
throw new Error("External game ZIP exceeds the platform size limit");
|
|
1223
|
+
}
|
|
1224
|
+
}
|
|
1225
|
+
if (!hasEntryPoint)
|
|
1226
|
+
throw new Error("External game archive requires a non-empty root index.html");
|
|
1227
|
+
for (const key of names) {
|
|
1228
|
+
let parent = key;
|
|
1229
|
+
while (parent.includes("/")) {
|
|
1230
|
+
parent = parent.slice(0, parent.lastIndexOf("/"));
|
|
1231
|
+
if (names.has(parent))
|
|
1232
|
+
throw new Error("External game archive has conflicting file and directory paths");
|
|
1233
|
+
}
|
|
1234
|
+
}
|
|
1235
|
+
const end = Buffer.alloc(22);
|
|
1236
|
+
end.writeUInt32LE(101010256, 0);
|
|
1237
|
+
end.writeUInt16LE(names.size, 8);
|
|
1238
|
+
end.writeUInt16LE(names.size, 10);
|
|
1239
|
+
end.writeUInt32LE(centralBytes, 12);
|
|
1240
|
+
end.writeUInt32LE(offset, 16);
|
|
1241
|
+
const bytes = offset + centralBytes + end.length;
|
|
1242
|
+
parts.push(...central, end);
|
|
1243
|
+
const hash = createHash3("sha256");
|
|
1244
|
+
for (const part of parts)
|
|
1245
|
+
hash.update(part);
|
|
1246
|
+
signal?.throwIfAborted();
|
|
1247
|
+
return { parts, bytes, sha256: hash.digest("hex") };
|
|
1248
|
+
}
|
|
1249
|
+
|
|
1250
|
+
// vendor/agent-cli/dist/src/artifacts/external-game-upload.js
|
|
1251
|
+
import { createHash as createHash4 } from "node:crypto";
|
|
1252
|
+
import { promisify } from "node:util";
|
|
1253
|
+
import { gzip } from "node:zlib";
|
|
1254
|
+
var compress = promisify(gzip);
|
|
1255
|
+
var api = "/api/ms/external-game-uploads";
|
|
1256
|
+
var idPattern = /^[A-Za-z0-9_-]{1,128}$/;
|
|
1257
|
+
var digestPattern = /^[0-9a-f]{64}$/;
|
|
1258
|
+
async function encodeExternalGameContent(archive, signal) {
|
|
1259
|
+
signal?.throwIfAborted();
|
|
1260
|
+
if (!Number.isSafeInteger(archive?.bytes) || archive.bytes < 22 || archive.bytes > EXTERNAL_GAME_UPLOAD_LIMITS.archiveBytes || !Array.isArray(archive.parts) || !digestPattern.test(archive.sha256 ?? "")) {
|
|
1261
|
+
throw new Error("Invalid external game ZIP metadata or platform size limit");
|
|
1262
|
+
}
|
|
1263
|
+
let bytes = 0;
|
|
1264
|
+
for (const part of archive.parts) {
|
|
1265
|
+
signal?.throwIfAborted();
|
|
1266
|
+
if (!(part instanceof Uint8Array))
|
|
1267
|
+
throw new Error("Invalid external game ZIP part");
|
|
1268
|
+
bytes += part.byteLength;
|
|
1269
|
+
if (bytes > archive.bytes)
|
|
1270
|
+
throw new Error("External game ZIP length does not match its prepared metadata");
|
|
1271
|
+
}
|
|
1272
|
+
if (bytes !== archive.bytes)
|
|
1273
|
+
throw new Error("External game ZIP length does not match its prepared metadata");
|
|
1274
|
+
const original = Buffer.concat(archive.parts, bytes);
|
|
1275
|
+
if (createHash4("sha256").update(original).digest("hex") !== archive.sha256) {
|
|
1276
|
+
throw new Error("External game ZIP SHA-256 does not match its prepared metadata");
|
|
1277
|
+
}
|
|
1278
|
+
let encoded;
|
|
1279
|
+
try {
|
|
1280
|
+
encoded = await compress(original, { maxOutputLength: EXTERNAL_GAME_UPLOAD_LIMITS.gzipBytes });
|
|
1281
|
+
} catch (error) {
|
|
1282
|
+
if (error.code === "ERR_BUFFER_TOO_LARGE") {
|
|
1283
|
+
throw new Error("Compressed external game ZIP exceeds the platform size limit");
|
|
1284
|
+
}
|
|
1285
|
+
throw error;
|
|
1286
|
+
}
|
|
1287
|
+
signal?.throwIfAborted();
|
|
1288
|
+
if (encoded.length > EXTERNAL_GAME_UPLOAD_LIMITS.gzipBytes)
|
|
1289
|
+
throw new Error("Compressed external game ZIP exceeds the platform size limit");
|
|
1290
|
+
const body = { archive_encoded: encoded.toString("base64") };
|
|
1291
|
+
if (Buffer.byteLength(JSON.stringify(body)) > EXTERNAL_GAME_UPLOAD_LIMITS.jsonBytes) {
|
|
1292
|
+
throw new Error("External game JSON exceeds the platform size limit");
|
|
1293
|
+
}
|
|
1294
|
+
return body;
|
|
1295
|
+
}
|
|
1296
|
+
async function externalGameUploadRequest(kind, options, signal) {
|
|
1297
|
+
signal?.throwIfAborted();
|
|
1298
|
+
if (kind === "prepare") {
|
|
1299
|
+
if (!options.input || typeof options.input !== "object" || Array.isArray(options.input)) {
|
|
1300
|
+
throw new Error("External game prepare input is required");
|
|
1301
|
+
}
|
|
1302
|
+
return { endpoint: api + "/prepare", method: "POST", body: { ...options.input } };
|
|
1303
|
+
}
|
|
1304
|
+
if (typeof options.id !== "string" || !idPattern.test(options.id))
|
|
1305
|
+
throw new Error("Invalid external game upload ID");
|
|
1306
|
+
const endpoint = api + "/" + options.id;
|
|
1307
|
+
if (kind === "upload") {
|
|
1308
|
+
if (!options.archive)
|
|
1309
|
+
throw new Error("External game ZIP is required");
|
|
1310
|
+
return { endpoint: endpoint + "/content", method: "POST", body: await encodeExternalGameContent(options.archive, signal) };
|
|
1311
|
+
}
|
|
1312
|
+
if (kind === "commit")
|
|
1313
|
+
return { endpoint: endpoint + "/commit", method: "POST", body: {} };
|
|
1314
|
+
if (kind === "status")
|
|
1315
|
+
return { endpoint, method: "GET" };
|
|
1316
|
+
throw new Error("Unknown external game upload operation");
|
|
1317
|
+
}
|
|
1318
|
+
function safeId(value) {
|
|
1319
|
+
return typeof value === "string" && idPattern.test(value);
|
|
1320
|
+
}
|
|
1321
|
+
function parseExternalGameUploadReceipt(value, options = {}) {
|
|
1322
|
+
if (value === null || typeof value !== "object" || Array.isArray(value))
|
|
1323
|
+
throw new Error("Invalid external game upload receipt");
|
|
1324
|
+
const data = value;
|
|
1325
|
+
if (!safeId(data.upload_id) || options.uploadId !== void 0 && data.upload_id !== options.uploadId || !["prepared", "uploaded", "draft_ready", "expired"].includes(data.state)) {
|
|
1326
|
+
throw new Error("Invalid external game upload receipt");
|
|
1327
|
+
}
|
|
1328
|
+
if (options.requireUploadPath && data.state === "prepared" && data.upload_path === void 0 || data.upload_path !== void 0 && data.upload_path !== `${api}/${data.upload_id}/content`) {
|
|
1329
|
+
throw new Error("Unexpected external game upload path");
|
|
1330
|
+
}
|
|
1331
|
+
const result = { upload_id: data.upload_id, state: data.state };
|
|
1332
|
+
if (result.state === "draft_ready") {
|
|
1333
|
+
if (!safeId(data.conversation_id) || !safeId(data.version_id) || options.conversationId !== void 0 && data.conversation_id !== options.conversationId) {
|
|
1334
|
+
throw new Error("Invalid external game draft version receipt");
|
|
1335
|
+
}
|
|
1336
|
+
result.conversation_id = data.conversation_id;
|
|
1337
|
+
result.version_id = data.version_id;
|
|
1338
|
+
if (data.external_manifest_sha256 !== void 0 || options.requireManifest) {
|
|
1339
|
+
if (typeof data.external_manifest_sha256 !== "string" || !digestPattern.test(data.external_manifest_sha256)) {
|
|
1340
|
+
throw new Error("Invalid external game draft manifest");
|
|
1341
|
+
}
|
|
1342
|
+
result.external_manifest_sha256 = data.external_manifest_sha256;
|
|
1343
|
+
}
|
|
1344
|
+
}
|
|
1345
|
+
return result;
|
|
1346
|
+
}
|
|
1347
|
+
|
|
1348
|
+
// vendor/agent-cli/dist/src/context/template-seed.js
|
|
1349
|
+
import { constants as constants5 } from "node:fs";
|
|
1350
|
+
import fs6 from "node:fs/promises";
|
|
1351
|
+
import path11 from "node:path";
|
|
1352
|
+
|
|
1353
|
+
// vendor/agent-cli/dist/src/context/template-refresh.js
|
|
1354
|
+
import fs4 from "node:fs/promises";
|
|
1355
|
+
import path9 from "node:path";
|
|
1356
|
+
var USER_OWNED_ROOTS = /* @__PURE__ */ new Set(["SPEC", "src", "Content", "configs"]);
|
|
1357
|
+
function normalizeRefreshPaths(value) {
|
|
1358
|
+
if (value === void 0)
|
|
1359
|
+
return [];
|
|
1360
|
+
if (!Array.isArray(value))
|
|
1361
|
+
throw new Error("Template refresh_paths must be an array");
|
|
1362
|
+
const paths = value.map((entry) => {
|
|
1363
|
+
if (typeof entry !== "string" || !entry || entry.includes("\\") || entry.includes("\0") || /[:*?<>"|]/.test(entry)) {
|
|
1364
|
+
throw new Error("Invalid template refresh path");
|
|
1365
|
+
}
|
|
1366
|
+
const segments = entry.split("/");
|
|
1367
|
+
if (USER_OWNED_ROOTS.has(segments[0]) || segments.some((segment) => !segment || segment === "." || segment === ".." || segment === ".git" || segment === ".claude" || segment === "node_modules" || segment.startsWith(".env"))) {
|
|
1368
|
+
throw new Error(`Invalid template refresh path: ${entry}`);
|
|
1369
|
+
}
|
|
1370
|
+
return entry;
|
|
1371
|
+
});
|
|
1372
|
+
return [...new Set(paths)].sort().filter((entry, _, all) => !all.some((parent) => parent !== entry && entry.startsWith(`${parent}/`)));
|
|
1373
|
+
}
|
|
1374
|
+
function isRefreshPath(relativePath, refreshPaths) {
|
|
1375
|
+
return refreshPaths.some((entry) => relativePath === entry || relativePath.startsWith(`${entry}/`));
|
|
1376
|
+
}
|
|
1377
|
+
async function assertTemplateTarget(root, relativePath) {
|
|
1378
|
+
let target = root;
|
|
1379
|
+
for (const segment of ["", ...relativePath.split(path9.sep)]) {
|
|
1380
|
+
if (segment)
|
|
1381
|
+
target = path9.join(target, segment);
|
|
1382
|
+
try {
|
|
1383
|
+
const stat4 = await fs4.lstat(target);
|
|
1384
|
+
if (stat4.isSymbolicLink())
|
|
1385
|
+
throw new Error(`Template target contains a symbolic link: ${relativePath}`);
|
|
1386
|
+
} catch (error) {
|
|
1387
|
+
if (error.code === "ENOENT")
|
|
1388
|
+
return;
|
|
1389
|
+
throw error;
|
|
1390
|
+
}
|
|
1391
|
+
}
|
|
1392
|
+
}
|
|
1393
|
+
|
|
1394
|
+
// vendor/agent-cli/dist/src/context/template-sync.js
|
|
1395
|
+
import fs5 from "node:fs/promises";
|
|
1396
|
+
import { constants as constants4 } from "node:fs";
|
|
1397
|
+
import path10 from "node:path";
|
|
1398
|
+
import { randomUUID as randomUUID3 } from "node:crypto";
|
|
1399
|
+
async function syncManagedTemplatePaths(options) {
|
|
1400
|
+
const copied = /* @__PURE__ */ new Set();
|
|
1401
|
+
for (const declared of options.refreshPaths) {
|
|
1402
|
+
const relative = path10.normalize(declared);
|
|
1403
|
+
options.signal.throwIfAborted();
|
|
1404
|
+
const source = path10.join(options.sourceDir, relative);
|
|
1405
|
+
if (!await statOrMissing(source))
|
|
1406
|
+
continue;
|
|
1407
|
+
const target = path10.join(options.targetDir, relative);
|
|
1408
|
+
await assertTemplateTarget(options.targetDir, relative);
|
|
1409
|
+
await assertRegularTree(target, options.signal);
|
|
1410
|
+
}
|
|
1411
|
+
for (const declared of options.refreshPaths) {
|
|
1412
|
+
const relative = path10.normalize(declared);
|
|
1413
|
+
const source = path10.join(options.sourceDir, relative);
|
|
1414
|
+
if (!await statOrMissing(source))
|
|
1415
|
+
continue;
|
|
1416
|
+
await withWritableParents(options.targetDir, path10.dirname(relative), async () => {
|
|
1417
|
+
await synchronize(options, relative, copied);
|
|
1418
|
+
});
|
|
1419
|
+
}
|
|
1420
|
+
return copied;
|
|
1421
|
+
}
|
|
1422
|
+
async function synchronize(options, relative, copied) {
|
|
1423
|
+
options.signal.throwIfAborted();
|
|
1424
|
+
const source = path10.join(options.sourceDir, relative), target = path10.join(options.targetDir, relative);
|
|
1425
|
+
const sourceStat = await fs5.lstat(source), previous = await statOrMissing(target);
|
|
1426
|
+
if (sourceStat.isSymbolicLink() || !sourceStat.isFile() && !sourceStat.isDirectory()) {
|
|
1427
|
+
throw new Error(`Template source is not a regular file or directory: ${relative}`);
|
|
1428
|
+
}
|
|
1429
|
+
if (sourceStat.isFile()) {
|
|
1430
|
+
if (!options.files.has(relative))
|
|
1431
|
+
return;
|
|
1432
|
+
if (previous?.isDirectory())
|
|
1433
|
+
await removeManagedTree(target, options.signal);
|
|
1434
|
+
if (await copyManagedFile(source, target, options.signal))
|
|
1435
|
+
copied.add(relative);
|
|
1436
|
+
return;
|
|
1437
|
+
}
|
|
1438
|
+
if (previous && !previous.isDirectory())
|
|
1439
|
+
await fs5.unlink(target);
|
|
1440
|
+
await fs5.mkdir(target, { recursive: true });
|
|
1441
|
+
const originalMode = (previous?.isDirectory() ? previous.mode : sourceStat.mode) & 511;
|
|
1442
|
+
await fs5.chmod(target, originalMode | 448);
|
|
1443
|
+
let completed = false;
|
|
1444
|
+
try {
|
|
1445
|
+
const sourceEntries = await fs5.readdir(source, { withFileTypes: true });
|
|
1446
|
+
const expected = new Set(sourceEntries.filter((entry) => entry.isDirectory() || options.files.has(path10.join(relative, entry.name))).map((entry) => entry.name));
|
|
1447
|
+
for (const name of await fs5.readdir(target)) {
|
|
1448
|
+
if (!expected.has(name))
|
|
1449
|
+
await removeManagedTree(path10.join(target, name), options.signal);
|
|
1450
|
+
}
|
|
1451
|
+
for (const entry of sourceEntries)
|
|
1452
|
+
await synchronize(options, path10.join(relative, entry.name), copied);
|
|
1453
|
+
completed = true;
|
|
1454
|
+
} finally {
|
|
1455
|
+
await fs5.chmod(target, completed ? originalMode & ~146 | 320 : originalMode);
|
|
1456
|
+
}
|
|
1457
|
+
}
|
|
1458
|
+
async function copyManagedFile(source, target, signal) {
|
|
1459
|
+
const data = await fs5.readFile(source), previous = await statOrMissing(target);
|
|
1460
|
+
if (previous && (previous.mode & 146) === 0 && data.equals(await fs5.readFile(target)))
|
|
1461
|
+
return false;
|
|
1462
|
+
const temporary = path10.join(path10.dirname(target), `.template-${randomUUID3()}.tmp`);
|
|
1463
|
+
try {
|
|
1464
|
+
signal.throwIfAborted();
|
|
1465
|
+
await fs5.copyFile(source, temporary, constants4.COPYFILE_EXCL);
|
|
1466
|
+
await fs5.chmod(temporary, (await fs5.stat(source)).mode & 365 | 256);
|
|
1467
|
+
signal.throwIfAborted();
|
|
1468
|
+
await replaceFile(temporary, target);
|
|
1469
|
+
return true;
|
|
1470
|
+
} finally {
|
|
1471
|
+
await fs5.rm(temporary, { force: true });
|
|
1472
|
+
}
|
|
1473
|
+
}
|
|
1474
|
+
async function withWritableParents(root, relative, body) {
|
|
1475
|
+
const changed = [];
|
|
1476
|
+
let directory = root;
|
|
1477
|
+
try {
|
|
1478
|
+
for (const segment of ["", ...relative.split(path10.sep).filter((segment2) => segment2 && segment2 !== ".")]) {
|
|
1479
|
+
if (segment)
|
|
1480
|
+
directory = path10.join(directory, segment);
|
|
1481
|
+
const previous = await statOrMissing(directory);
|
|
1482
|
+
if (!previous) {
|
|
1483
|
+
await fs5.mkdir(directory, { recursive: true });
|
|
1484
|
+
continue;
|
|
1485
|
+
}
|
|
1486
|
+
if (!previous.isDirectory() || previous.isSymbolicLink())
|
|
1487
|
+
throw new Error("Template target parent is not a regular directory");
|
|
1488
|
+
if ((previous.mode & 448) !== 448) {
|
|
1489
|
+
await fs5.chmod(directory, previous.mode | 448);
|
|
1490
|
+
changed.push({ directory, mode: previous.mode & 4095 });
|
|
1491
|
+
}
|
|
1492
|
+
}
|
|
1493
|
+
await body();
|
|
1494
|
+
} finally {
|
|
1495
|
+
const failures = [];
|
|
1496
|
+
for (const entry of changed.reverse()) {
|
|
1497
|
+
try {
|
|
1498
|
+
await fs5.chmod(entry.directory, entry.mode);
|
|
1499
|
+
} catch (error) {
|
|
1500
|
+
failures.push(error);
|
|
1501
|
+
}
|
|
1502
|
+
}
|
|
1503
|
+
if (failures.length)
|
|
1504
|
+
throw new AggregateError(failures, "Template parent permissions could not be restored");
|
|
1505
|
+
}
|
|
1506
|
+
}
|
|
1507
|
+
async function assertRegularTree(target, signal) {
|
|
1508
|
+
signal.throwIfAborted();
|
|
1509
|
+
const stat4 = await statOrMissing(target);
|
|
1510
|
+
if (!stat4)
|
|
1511
|
+
return;
|
|
1512
|
+
if (stat4.isSymbolicLink())
|
|
1513
|
+
throw new Error("Template target contains a symbolic link");
|
|
1514
|
+
if (stat4.isDirectory()) {
|
|
1515
|
+
for (const name of await fs5.readdir(target))
|
|
1516
|
+
await assertRegularTree(path10.join(target, name), signal);
|
|
1517
|
+
} else if (!stat4.isFile())
|
|
1518
|
+
throw new Error("Template target is not a regular file");
|
|
1519
|
+
}
|
|
1520
|
+
async function removeManagedTree(target, signal) {
|
|
1521
|
+
signal.throwIfAborted();
|
|
1522
|
+
const stat4 = await fs5.lstat(target);
|
|
1523
|
+
if (stat4.isSymbolicLink())
|
|
1524
|
+
throw new Error("Template target contains a symbolic link");
|
|
1525
|
+
if (!stat4.isDirectory()) {
|
|
1526
|
+
await fs5.unlink(target);
|
|
1527
|
+
return;
|
|
1528
|
+
}
|
|
1529
|
+
await fs5.chmod(target, stat4.mode | 448);
|
|
1530
|
+
let removed = false;
|
|
1531
|
+
try {
|
|
1532
|
+
for (const name of await fs5.readdir(target))
|
|
1533
|
+
await removeManagedTree(path10.join(target, name), signal);
|
|
1534
|
+
await fs5.rmdir(target);
|
|
1535
|
+
removed = true;
|
|
1536
|
+
} finally {
|
|
1537
|
+
if (!removed)
|
|
1538
|
+
await fs5.chmod(target, stat4.mode);
|
|
1539
|
+
}
|
|
1540
|
+
}
|
|
1541
|
+
async function statOrMissing(file) {
|
|
1542
|
+
try {
|
|
1543
|
+
return await fs5.lstat(file);
|
|
1544
|
+
} catch (error) {
|
|
1545
|
+
if (error.code === "ENOENT")
|
|
1546
|
+
return void 0;
|
|
1547
|
+
throw error;
|
|
1548
|
+
}
|
|
1549
|
+
}
|
|
1550
|
+
|
|
1551
|
+
// vendor/agent-cli/dist/src/context/template-seed.js
|
|
1552
|
+
async function seedProjectTemplate(sourceDir, targetDir, options = {}) {
|
|
1553
|
+
return withPreparation(options, async (signal) => {
|
|
1554
|
+
const copied = [];
|
|
1555
|
+
const skipped = [];
|
|
1556
|
+
const force = options.force === true;
|
|
1557
|
+
const refreshPaths = normalizeRefreshPaths(options.refreshPaths);
|
|
1558
|
+
let started = Date.now();
|
|
1559
|
+
const isNewProject = await isNewOrEmptyWorkspace(targetDir);
|
|
1560
|
+
options.log?.(`[agent-cli] template target inspection: ${Date.now() - started}ms`);
|
|
1561
|
+
started = Date.now();
|
|
1562
|
+
const files = (await listRelativeFiles(sourceDir, signal)).filter((file) => path11.basename(file) !== ".ok" && (!options.skipGitkeep || path11.basename(file) !== ".gitkeep"));
|
|
1563
|
+
options.log?.(`[agent-cli] template source scan: ${Date.now() - started}ms (${files.length} files)`);
|
|
1564
|
+
started = Date.now();
|
|
1565
|
+
const managedCopies = await syncManagedTemplatePaths({ sourceDir, targetDir, refreshPaths, files: new Set(files), signal });
|
|
1566
|
+
const directories = /* @__PURE__ */ new Map();
|
|
1567
|
+
for (let offset = 0; offset < files.length; offset += 4) {
|
|
1568
|
+
const batch = await Promise.allSettled(files.slice(offset, offset + 4).map(async (relPath) => {
|
|
1569
|
+
signal.throwIfAborted();
|
|
1570
|
+
const refresh = isRefreshPath(normalizeRel(relPath), refreshPaths);
|
|
1571
|
+
if (options.refreshOnly && !refresh)
|
|
1572
|
+
return false;
|
|
1573
|
+
await assertTemplateTarget(targetDir, relPath);
|
|
1574
|
+
if (refresh)
|
|
1575
|
+
return managedCopies.has(relPath);
|
|
1576
|
+
const targetPath = path11.join(targetDir, relPath);
|
|
1577
|
+
const parent = path11.dirname(targetPath);
|
|
1578
|
+
let directory = directories.get(parent);
|
|
1579
|
+
if (!directory) {
|
|
1580
|
+
directory = fs6.mkdir(parent, { recursive: true });
|
|
1581
|
+
directories.set(parent, directory);
|
|
1582
|
+
}
|
|
1583
|
+
await directory;
|
|
1584
|
+
signal.throwIfAborted();
|
|
1585
|
+
try {
|
|
1586
|
+
await fs6.copyFile(path11.join(sourceDir, relPath), targetPath, force ? 0 : constants5.COPYFILE_EXCL);
|
|
1587
|
+
return true;
|
|
1588
|
+
} catch (error) {
|
|
1589
|
+
if (!force && error.code === "EEXIST")
|
|
1590
|
+
return false;
|
|
1591
|
+
throw error;
|
|
1592
|
+
}
|
|
1593
|
+
}));
|
|
1594
|
+
for (const [index, result] of batch.entries()) {
|
|
1595
|
+
if (result.status === "rejected")
|
|
1596
|
+
throw result.reason;
|
|
1597
|
+
(result.value ? copied : skipped).push(normalizeRel(files[offset + index]));
|
|
1598
|
+
}
|
|
1599
|
+
}
|
|
1600
|
+
options.log?.(`[agent-cli] template directory preparation and file copy: ${Date.now() - started}ms`);
|
|
1601
|
+
return {
|
|
1602
|
+
copied,
|
|
1603
|
+
skipped,
|
|
1604
|
+
total: copied.length + skipped.length,
|
|
1605
|
+
isNewProject
|
|
1606
|
+
};
|
|
1607
|
+
});
|
|
1608
|
+
}
|
|
1609
|
+
async function isNewOrEmptyWorkspace(targetDir) {
|
|
1610
|
+
let stat4;
|
|
1611
|
+
try {
|
|
1612
|
+
stat4 = await fs6.lstat(targetDir);
|
|
1613
|
+
} catch (err) {
|
|
1614
|
+
if (err.code === "ENOENT") {
|
|
1615
|
+
return true;
|
|
1616
|
+
}
|
|
1617
|
+
throw err;
|
|
1618
|
+
}
|
|
1619
|
+
if (!stat4.isDirectory()) {
|
|
1620
|
+
return false;
|
|
1621
|
+
}
|
|
1622
|
+
const entries = await fs6.readdir(targetDir);
|
|
1623
|
+
if (entries.length === 0) {
|
|
1624
|
+
return true;
|
|
1625
|
+
}
|
|
1626
|
+
const hasPackageJson = await pathExists(path11.join(targetDir, "package.json"));
|
|
1627
|
+
const hasContent = await pathExists(path11.join(targetDir, "Content"));
|
|
1628
|
+
const hasSpec = await pathExists(path11.join(targetDir, "SPEC"));
|
|
1629
|
+
const hasProjectGodot = await pathExists(path11.join(targetDir, "project.godot"));
|
|
1630
|
+
return !(hasPackageJson || hasContent || hasSpec || hasProjectGodot);
|
|
1631
|
+
}
|
|
1632
|
+
async function listRelativeFiles(sourceDir, signal) {
|
|
1633
|
+
const files = [];
|
|
1634
|
+
await walkDirectory(sourceDir, "", files, signal);
|
|
1635
|
+
return files;
|
|
1636
|
+
}
|
|
1637
|
+
async function walkDirectory(rootDir, relDir, files, signal) {
|
|
1638
|
+
signal.throwIfAborted();
|
|
1639
|
+
const currentDir = relDir ? path11.join(rootDir, relDir) : rootDir;
|
|
1640
|
+
const entries = await fs6.readdir(currentDir, { withFileTypes: true });
|
|
1641
|
+
for (const entry of entries) {
|
|
1642
|
+
signal.throwIfAborted();
|
|
1643
|
+
const relPath = relDir ? path11.join(relDir, entry.name) : entry.name;
|
|
1644
|
+
if (entry.isSymbolicLink())
|
|
1645
|
+
throw new Error(`Template source contains a symbolic link: ${relPath}`);
|
|
1646
|
+
if (!entry.isFile() && !entry.isDirectory())
|
|
1647
|
+
throw new Error(`Template source is not a regular file: ${relPath}`);
|
|
1648
|
+
if (entry.isDirectory()) {
|
|
1649
|
+
await walkDirectory(rootDir, relPath, files, signal);
|
|
1650
|
+
continue;
|
|
1651
|
+
}
|
|
1652
|
+
files.push(relPath);
|
|
1653
|
+
}
|
|
1654
|
+
}
|
|
1655
|
+
async function pathExists(targetPath) {
|
|
1656
|
+
try {
|
|
1657
|
+
await fs6.lstat(targetPath);
|
|
1658
|
+
return true;
|
|
1659
|
+
} catch (err) {
|
|
1660
|
+
if (err.code === "ENOENT") {
|
|
1661
|
+
return false;
|
|
1662
|
+
}
|
|
1663
|
+
throw err;
|
|
1664
|
+
}
|
|
1665
|
+
}
|
|
1666
|
+
function normalizeRel(relPath) {
|
|
1667
|
+
return relPath.replace(/\\/g, "/");
|
|
1668
|
+
}
|
|
1669
|
+
|
|
1670
|
+
// sdk/finalize-game-context.mjs
|
|
1671
|
+
import path12 from "node:path";
|
|
1672
|
+
import { readFile as readFile4, realpath as realpath4, lstat as lstat3 } from "node:fs/promises";
|
|
1673
|
+
async function finalizeGameContext({ workspaceDir, contextDir, engine, onLog = () => {
|
|
1674
|
+
} }, signal) {
|
|
1675
|
+
if (!["js", "js3d"].includes(engine) || !path12.isAbsolute(workspaceDir) || !path12.isAbsolute(contextDir)) throw new Error("Invalid game finalization input");
|
|
1676
|
+
signal?.throwIfAborted();
|
|
1677
|
+
const workspace = await realpath4(workspaceDir), context = await realpath4(contextDir);
|
|
1678
|
+
const file = path12.join(context, "hooks/hooks.json");
|
|
1679
|
+
if (!(await lstat3(file)).isFile() || (await lstat3(file)).isSymbolicLink()) throw new Error("Game hooks must be a regular file");
|
|
1680
|
+
const raw = await readFile4(file, { encoding: "utf8", signal });
|
|
1681
|
+
if (Buffer.byteLength(raw) > 64 * 1024) throw new Error("Game hooks exceed size limit");
|
|
1682
|
+
const hooks = JSON.parse(raw);
|
|
1683
|
+
if (!hooks || typeof hooks !== "object" || Array.isArray(hooks) || Object.keys(hooks).some((key) => key !== "run:complete") || !Array.isArray(hooks["run:complete"]) || !hooks["run:complete"].length) throw new Error("Unsupported game finalization declarations");
|
|
1684
|
+
const invocations = [];
|
|
1685
|
+
for (const hook of hooks["run:complete"]) {
|
|
1686
|
+
if (!hook || typeof hook !== "object" || Object.keys(hook).some((key) => !["name", "when", "command", "cwd", "timeoutMs", "required"].includes(key)) || hook.name !== "export-config" || hook.when !== "workspace-changed" || hook.cwd !== "workspace" || hook.required !== void 0 && typeof hook.required !== "boolean" || JSON.stringify(hook.command) !== JSON.stringify(["node", "${CONTEXT_DIR}/skills/export-config/scripts/export-config.mjs"]) || !Number.isInteger(hook.timeoutMs) || hook.timeoutMs < 1e3 || hook.timeoutMs > 6e5) throw new Error("Unsupported game export hook");
|
|
1687
|
+
const script = path12.join(context, "skills/export-config/scripts/export-config.mjs");
|
|
1688
|
+
const actual = await realpath4(script);
|
|
1689
|
+
if (actual !== script || !(await lstat3(script)).isFile()) throw new Error("Game export hook must stay inside the bound context");
|
|
1690
|
+
invocations.push({ script, timeoutMs: hook.timeoutMs });
|
|
1691
|
+
}
|
|
1692
|
+
if (invocations.length !== 1) throw new Error("Expected exactly one game export hook");
|
|
1693
|
+
const env = Object.fromEntries(Object.entries(process.env).filter(([key]) => !key.startsWith("PLATFORM_") && key !== "AGENT_CLI_TOKEN"));
|
|
1694
|
+
Object.assign(env, { CRAFT_CONTEXT_DIR: context, CRAFT_PROJECT_DIR: workspace });
|
|
1695
|
+
for (const invocation of invocations) {
|
|
1696
|
+
signal?.throwIfAborted();
|
|
1697
|
+
onLog("Exporting configuration with the bound context");
|
|
1698
|
+
const result = await runProcess(process.execPath, [invocation.script], { cwd: workspace, env, timeoutMs: invocation.timeoutMs, signal, readOnlyDirectories: [context] });
|
|
1699
|
+
signal?.throwIfAborted();
|
|
1700
|
+
if (result.exitCode !== 0 || result.timedOut || result.aborted) throw new Error("Game configuration export failed: " + (result.timedOut ? "timeout" : result.aborted ? "cancelled" : (result.stderr || result.stdout).slice(-2e3)));
|
|
1701
|
+
onLog("Configuration export completed");
|
|
1702
|
+
}
|
|
1703
|
+
}
|
|
1704
|
+
export {
|
|
1705
|
+
buildJsStatic,
|
|
1706
|
+
encodeExternalGameArchive,
|
|
1707
|
+
encodeExternalGameContent,
|
|
1708
|
+
externalGameUploadRequest,
|
|
1709
|
+
finalizeGameContext,
|
|
1710
|
+
installProjectDependencies,
|
|
1711
|
+
parseExternalGameUploadReceipt,
|
|
1712
|
+
prepareBrowserEnvironment,
|
|
1713
|
+
prepareStaticArtifacts,
|
|
1714
|
+
runProcess,
|
|
1715
|
+
seedProjectTemplate
|
|
1716
|
+
};
|