From 4134044b26d8e53b29806ddfd6d7f43b347e966f Mon Sep 17 00:00:00 2001 From: Cole Miller Date: Mon, 13 Oct 2025 10:30:40 -0400 Subject: [PATCH] windows: Fix semantic merge conflict with `ShellKind::new` (#40107) Release Notes: - N/A --- crates/task/src/shell_builder.rs | 13 +++++++++++++ crates/task/src/task.rs | 6 +++--- crates/terminal/src/terminal.rs | 2 +- 3 files changed, 17 insertions(+), 4 deletions(-) diff --git a/crates/task/src/shell_builder.rs b/crates/task/src/shell_builder.rs index 2c3e17d3b12f27aa36daea4c2301cbad77f82996..55cffa24452a0a71887f25e1bc13a7ce7d642332 100644 --- a/crates/task/src/shell_builder.rs +++ b/crates/task/src/shell_builder.rs @@ -157,4 +157,17 @@ mod test { assert_eq!(program, "nu"); assert_eq!(args, vec!["-i", "-c", "(echo nothing) ShellKind { + pub fn shell_kind(&self, is_windows: bool) -> ShellKind { match self { - Shell::Program(program) => ShellKind::new(program), - Shell::WithArguments { program, .. } => ShellKind::new(program), + Shell::Program(program) => ShellKind::new(program, is_windows), + Shell::WithArguments { program, .. } => ShellKind::new(program, is_windows), Shell::System => ShellKind::system(), } } diff --git a/crates/terminal/src/terminal.rs b/crates/terminal/src/terminal.rs index 6c76af0542df09e3204e05c4cd609b08aa3849b5..cf6851ac346cbc26b88029822fddb88b408be16e 100644 --- a/crates/terminal/src/terminal.rs +++ b/crates/terminal/src/terminal.rs @@ -495,7 +495,7 @@ impl TerminalBuilder { .unwrap_or(params.program.clone()) }); - let shell_kind = shell.shell_kind(); + let shell_kind = shell.shell_kind(cfg!(windows)); let pty_options = { let alac_shell = shell_params.as_ref().map(|params| {