diff --git a/apps/ai-game-creator-shell/scripts/check-config.mjs b/apps/ai-game-creator-shell/scripts/check-config.mjs index f2c19ac58..037526aaa 100644 --- a/apps/ai-game-creator-shell/scripts/check-config.mjs +++ b/apps/ai-game-creator-shell/scripts/check-config.mjs @@ -1285,6 +1285,9 @@ if (tauriConfig.identifier !== 'world.genarrative.ai-game-creator') { throw new Error('AI game creator shell identifier drifted'); } +const expectedBundledDesignAgentResources = { + 'design-agent': 'design-agent', +}; const expectedBundledCodexResources = { 'resources/codex/win-x64/bin/codex.exe': 'codex/win-x64/bin/codex.exe', 'resources/codex/win-x64/bin/codex-code-mode-host.exe': @@ -1300,16 +1303,33 @@ const expectedBundledCodexResources = { 'resources/codex/win-x64/NOTICE.md': 'codex/win-x64/NOTICE.md', 'resources/codex/win-x64/manifest.json': 'codex/win-x64/manifest.json', }; -if (tauriConfig.bundle?.resources !== undefined) { - throw new Error( - 'AI game creator shell base Tauri config must not require Windows-only Codex resources', - ); +assert.deepEqual( + tauriConfig.bundle?.resources, + expectedBundledDesignAgentResources, + 'AI game creator shell base Tauri config must bundle the design-agent resource pack', +); +for (const key of Object.keys(tauriConfig.bundle?.resources ?? {})) { + if (String(key).includes('codex')) { + throw new Error( + 'AI game creator shell base Tauri config must not require Windows-only Codex resources', + ); + } } assert.deepEqual( windowsTauriConfig.bundle?.resources, expectedBundledCodexResources, 'AI game creator shell Windows Tauri config must bundle the complete pinned Codex resource set', ); +if ( + Object.prototype.hasOwnProperty.call( + windowsTauriConfig.bundle?.resources ?? {}, + 'design-agent', + ) +) { + throw new Error( + 'design-agent resource pack must not be mixed into the Windows Codex sidecar bundle', + ); +} if (windowsTauriConfig.bundle?.useLocalToolsDir !== true) { throw new Error( 'AI game creator shell Windows Tauri config must cache bundling tools in the project target directory', diff --git a/apps/ai-game-creator-shell/src-tauri/tauri.conf.json b/apps/ai-game-creator-shell/src-tauri/tauri.conf.json index 1eb8e0319..15e394d98 100644 --- a/apps/ai-game-creator-shell/src-tauri/tauri.conf.json +++ b/apps/ai-game-creator-shell/src-tauri/tauri.conf.json @@ -31,6 +31,9 @@ "bundle": { "active": true, "targets": "all", + "resources": { + "design-agent": "design-agent" + }, "linux": { "deb": { "depends": ["bubblewrap"] diff --git a/apps/ai-game-creator-shell/src-tauri/tauri.windows.conf.json b/apps/ai-game-creator-shell/src-tauri/tauri.windows.conf.json index 8e53a3cd4..ad932ab58 100644 --- a/apps/ai-game-creator-shell/src-tauri/tauri.windows.conf.json +++ b/apps/ai-game-creator-shell/src-tauri/tauri.windows.conf.json @@ -11,8 +11,7 @@ "resources/codex/win-x64/codex-resources/codex-windows-sandbox-setup.exe": "codex/win-x64/codex-resources/codex-windows-sandbox-setup.exe", "resources/codex/win-x64/codex-package.json": "codex/win-x64/codex-package.json", "resources/codex/win-x64/NOTICE.md": "codex/win-x64/NOTICE.md", - "resources/codex/win-x64/manifest.json": "codex/win-x64/manifest.json", - "design-agent": "design-agent" + "resources/codex/win-x64/manifest.json": "codex/win-x64/manifest.json" } } }