From 973e86df278ac91ea0059220aefc51d1c3c7288c Mon Sep 17 00:00:00 2001 From: "Paul Gauthier (aider)" Date: Tue, 26 Nov 2024 19:52:46 -0800 Subject: [PATCH] fix: use cwd=root when executing shell commands --- aider/coders/base_coder.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aider/coders/base_coder.py b/aider/coders/base_coder.py index bec667830..478d6f888 100755 --- a/aider/coders/base_coder.py +++ b/aider/coders/base_coder.py @@ -2112,7 +2112,7 @@ class Coder: self.io.tool_output(f"Running {command}") # Add the command to input history self.io.add_to_input_history(f"/run {command.strip()}") - exit_status, output = run_cmd(command, error_print=self.io.tool_error) + exit_status, output = run_cmd(command, error_print=self.io.tool_error, cwd=self.root) if output: accumulated_output += f"Output from {command}\n{output}\n"