diff --git a/apps/x/apps/main/bundle.mjs b/apps/x/apps/main/bundle.mjs index 125c4575..2444e356 100644 --- a/apps/x/apps/main/bundle.mjs +++ b/apps/x/apps/main/bundle.mjs @@ -22,7 +22,7 @@ await esbuild.build({ platform: 'node', target: 'node20', outfile: './.package/dist/main.cjs', - external: ['electron', 'electron-squirrel-startup'], // Provided by Electron runtime + external: ['electron'], // Provided by Electron runtime // Use CommonJS format - many dependencies use require() which doesn't work // well with esbuild's ESM shim. CJS handles dynamic requires natively. format: 'cjs', diff --git a/apps/x/apps/main/package.json b/apps/x/apps/main/package.json index a3ef9e56..38e31b88 100644 --- a/apps/x/apps/main/package.json +++ b/apps/x/apps/main/package.json @@ -13,6 +13,7 @@ "@x/core": "workspace:*", "@x/shared": "workspace:*", "chokidar": "^4.0.3", + "electron-squirrel-startup": "^1.0.1", "update-electron-app": "^3.1.2", "zod": "^4.2.1" }, diff --git a/apps/x/pnpm-lock.yaml b/apps/x/pnpm-lock.yaml index 129e92e2..2b155fd5 100644 --- a/apps/x/pnpm-lock.yaml +++ b/apps/x/pnpm-lock.yaml @@ -50,6 +50,9 @@ importers: chokidar: specifier: ^4.0.3 version: 4.0.3 + electron-squirrel-startup: + specifier: ^1.0.1 + version: 1.0.1 update-electron-app: specifier: ^3.1.2 version: 3.1.2 @@ -3859,6 +3862,9 @@ packages: engines: {node: '>= 16'} hasBin: true + electron-squirrel-startup@1.0.1: + resolution: {integrity: sha512-sTfFIHGku+7PsHLJ7v0dRcZNkALrV+YEozINTW8X1nM//e5O3L+rfYuvSW00lmGHnYmUjARZulD8F2V8ISI9RA==} + electron-to-chromium@1.5.267: resolution: {integrity: sha512-0Drusm6MVRXSOJpGbaSVgcQsuB4hEkMpHXaVstcPmhu5LIedxs1xNK/nIxmQIU/RPC0+1/o0AVZfBTkTNJOdUw==} @@ -11198,6 +11204,12 @@ snapshots: - supports-color optional: true + electron-squirrel-startup@1.0.1: + dependencies: + debug: 2.6.9 + transitivePeerDependencies: + - supports-color + electron-to-chromium@1.5.267: {} electron-winstaller@5.4.0: