import { build } from 'esbuild' await build({ entryPoints: ['scripts/claude-kernel-integration.ts'], outfile: '.tmp/claude-kernel-integration.mjs', bundle: true, platform: 'node', format: 'esm', external: ['@anthropic-ai/claude-agent-sdk'], logLevel: 'warning', plugins: [{ name: 'claude-kernel-electron-stub', setup(plugin) { plugin.onResolve({ filter: /^electron$/ }, () => ({ path: 'electron', namespace: 'claude-test' })) plugin.onLoad({ filter: /.*/, namespace: 'claude-test' }, () => ({ loader: 'js', contents: ` export const app = { getPath: (name) => name === 'userData' ? process.env.CLAUDE_TEST_USER_DATA : process.cwd(), getAppPath: () => process.cwd() }; ` })) } }] })