From 8b517cac629fe2721be7f4ae3c090a2706aa735b Mon Sep 17 00:00:00 2001 From: "Paul Gauthier (aider)" Date: Fri, 9 Aug 2024 08:07:22 -0300 Subject: [PATCH] feat: Add cmd_map command to print the current repository map --- aider/commands.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/aider/commands.py b/aider/commands.py index 2e44f3fb5..7c2845f1e 100644 --- a/aider/commands.py +++ b/aider/commands.py @@ -934,6 +934,13 @@ class Commands: except Exception as e: self.io.tool_error(f"Error processing clipboard content: {e}") + def cmd_map(self, args): + "Print out the current repository map" + repo_map = self.coder.get_repo_map() + if repo_map: + self.io.tool_output(repo_map) + else: + self.io.tool_output("No repository map available.") def expand_subdir(file_path): file_path = Path(file_path)