diff --git a/crates/agent_servers/src/acp.rs b/crates/agent_servers/src/acp.rs index 9386a9493df021e09a6e868536b9a9fb8db32391..8df4eb4ed14335e7c63f214dbfc7f60678068b98 100644 --- a/crates/agent_servers/src/acp.rs +++ b/crates/agent_servers/src/acp.rs @@ -30,8 +30,6 @@ pub struct AcpConnection { sessions: Rc>>, auth_methods: Vec, agent_capabilities: acp::AgentCapabilities, - default_mode: Option, - root_dir: PathBuf, // NB: Don't move this into the wait_task, since we need to ensure the process is // killed on drop (setting kill_on_drop on the command seems to not always work). child: smol::process::Child, @@ -70,11 +68,8 @@ impl AcpConnection { .current_dir(root_dir) .stdin(std::process::Stdio::piped()) .stdout(std::process::Stdio::piped()) - .stderr(std::process::Stdio::piped()); - if !is_remote { - child.current_dir(root_dir); - } - let mut child = child.spawn()?; + .stderr(std::process::Stdio::piped()) + .spawn()?; let stdout = child.stdout.take().context("Failed to take stdout")?; let stdin = child.stdin.take().context("Failed to take stdin")?;