fix(release): call tauri binary directly, not via desktop build script
Node execSync runs via cmd.exe on Windows, which preserves the `--` separator pnpm injects between the script name and forwarded args. Tauri CLI then forwards that `--` to cargo, which rejects `--bundles` with "unexpected argument". Invoking `pnpm exec tauri build --bundles nsis` skips the script indirection so no `--` is emitted. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
+5
-1
@@ -88,7 +88,11 @@ const buildEnv = {
|
||||
TAURI_SIGNING_PRIVATE_KEY: signingKey,
|
||||
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: env.TAURI_SIGNING_PRIVATE_KEY_PASSWORD ?? '',
|
||||
};
|
||||
execSync('pnpm --filter @chat-app/desktop build -- --bundles nsis', {
|
||||
// Call the tauri binary directly (not via the desktop `build` script) so the
|
||||
// `--` separator pnpm normally injects doesn't get forwarded to cargo. When
|
||||
// run from cmd.exe (Node's default execSync shell on Windows) pnpm preserves
|
||||
// the `--`, which cargo then rejects with "unexpected argument '--bundles'".
|
||||
execSync('pnpm --filter @chat-app/desktop exec tauri build --bundles nsis', {
|
||||
cwd: ROOT,
|
||||
env: buildEnv,
|
||||
stdio: 'inherit',
|
||||
|
||||
Reference in New Issue
Block a user