From 07d758a6318a519d22b68abcc5eb7ddafb67608b Mon Sep 17 00:00:00 2001 From: Helios Agent Date: Tue, 3 Mar 2026 14:51:31 +0100 Subject: [PATCH] fix(client): use cmd /D to disable AutoRun, prevents terminal clear on each command --- crates/client/src/shell.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/crates/client/src/shell.rs b/crates/client/src/shell.rs index ebadc40..517ee1f 100644 --- a/crates/client/src/shell.rs +++ b/crates/client/src/shell.rs @@ -80,7 +80,9 @@ async fn spawn_cmd_windows( let full_cmd = format!("chcp 65001 >nul 2>&1 && {command}"); let mut cmd = Command::new("cmd.exe"); - cmd.args(["/C", &full_cmd]); + // /D disables AutoRun registry commands (prevents user's `clear` or other + // startup hooks from wiping the client's terminal output). + cmd.args(["/D", "/C", &full_cmd]); if let Some(ref dir) = cwd { cmd.current_dir(dir);