task: Fix ShellBuilder::redirect_stdin_to_dev_null constructing invalid commands on windows (#39227)

Release Notes:

- Fixed agents not being able to use the terminal tool with powershell

Co-authored-by: Cole Miller <cole@zed.dev>
This commit is contained in:
Lukas Wirth
2025-09-30 17:55:46 +00:00
committed by GitHub
co-authored by Cole Miller
parent ace617037f
commit 67ebb1f795
+1 -1
View File
@@ -288,7 +288,7 @@ impl ShellBuilder {
combined_command.push_str(") </dev/null"); combined_command.push_str(") </dev/null");
} }
ShellKind::PowerShell => { ShellKind::PowerShell => {
combined_command.insert_str(0, "$null | {"); combined_command.insert_str(0, "`$null | & {");
combined_command.push_str("}"); combined_command.push_str("}");
} }
ShellKind::Cmd => { ShellKind::Cmd => {