fix: hide node.exe console window on Windows & bump v2.3.6

Add CREATE_NO_WINDOW (0x08000000) creation flag to the sidecar
Command::new() spawn on Windows. Without this, node.exe inherits
a visible console window that overlays the Tauri GUI.
This commit is contained in:
Elie Habib
2026-02-16 09:00:16 +04:00
parent 46010c3911
commit 700132adad
5 changed files with 9 additions and 5 deletions

View File

@@ -7,6 +7,8 @@ use std::process::{Child, Command, Stdio};
use std::sync::Mutex;
use std::time::{SystemTime, UNIX_EPOCH};
use std::env;
#[cfg(windows)]
use std::os::windows::process::CommandExt;
use keyring::Entry;
use reqwest::Url;
@@ -552,6 +554,8 @@ fn start_local_api(app: &AppHandle) -> Result<(), String> {
drop(token_slot);
let mut cmd = Command::new(&node_binary);
#[cfg(windows)]
cmd.creation_flags(0x08000000); // CREATE_NO_WINDOW — hide the node.exe console
// Sanitize paths for Node.js on Windows: strip \\?\ UNC prefix and set
// explicit working directory to avoid bare drive-letter CWD issues that
// cause EISDIR errors in Node.js module resolution.