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| {