Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

Don't parse windows commandlines in debugger launch (#30586)

Julia Ryanc6e69fae1731
diff --git a/crates/debugger_ui/src/new_session_modal.rs b/crates/debugger_ui/src/new_session_modal.rs
index 6b283a095b6..c9de0da651b 100644
--- a/crates/debugger_ui/src/new_session_modal.rs
+++ b/crates/debugger_ui/src/new_session_modal.rs
@@ -736,6 +736,14 @@ impl CustomMode {
pub(super) fn debug_request(&self, cx: &App) -> task::LaunchRequest {
let path = self.cwd.read(cx).text(cx);
+ if cfg!(windows) {
+ return task::LaunchRequest {
+ program: self.program.read(cx).text(cx),
+ cwd: path.is_empty().not().then(|| PathBuf::from(path)),
+ args: Default::default(),
+ env: Default::default(),
+ };
+ }
let command = self.program.read(cx).text(cx);
let mut args = shlex::split(&command).into_iter().flatten().peekable();
let mut env = FxHashMap::default();