From 8da4874db9bca20ce9453fb03b99f6aa01813b38 Mon Sep 17 00:00:00 2001 From: pcamp Date: Wed, 21 Aug 2024 08:11:34 -0500 Subject: [PATCH 1/4] Correct description of map-refresh command. Delete " and print it out" because the map-refresh command doesn't print out the map. --- aider/website/docs/usage/commands.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aider/website/docs/usage/commands.md b/aider/website/docs/usage/commands.md index 2046e86ee..a108038ed 100644 --- a/aider/website/docs/usage/commands.md +++ b/aider/website/docs/usage/commands.md @@ -29,7 +29,7 @@ cog.out(get_help_md()) | **/lint** | Lint and fix provided files or in-chat files if none provided | | **/ls** | List all known files and indicate which are included in the chat session | | **/map** | Print out the current repository map | -| **/map-refresh** | Force a refresh of the repository map and print it out | +| **/map-refresh** | Force a refresh of the repository map | | **/model** | Switch to a new LLM | | **/models** | Search the list of available models | | **/quit** | Exit the application | From 853d9a5b2a46573adc80e87dd9447cf6a8d5c71b Mon Sep 17 00:00:00 2001 From: pcamp Date: Wed, 21 Aug 2024 08:13:29 -0500 Subject: [PATCH 2/4] Correct description of map-refresh command. Delete " and print it out" because the map-refresh command doesn't print out the map. --- aider/commands.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aider/commands.py b/aider/commands.py index 89fc52494..e74b28ca0 100644 --- a/aider/commands.py +++ b/aider/commands.py @@ -1046,7 +1046,7 @@ class Commands: self.io.tool_output("No repository map available.") def cmd_map_refresh(self, args): - "Force a refresh of the repository map and print it out" + "Force a refresh of the repository map" repo_map = self.coder.get_repo_map(force_refresh=True) if repo_map: self.io.tool_output("The repo map has been refreshed, use /map to view it.") From 387441b48a0dda7f39e5467bbdc656dfe3b82677 Mon Sep 17 00:00:00 2001 From: "Paul Gauthier (aider)" Date: Wed, 21 Aug 2024 09:33:16 -0700 Subject: [PATCH 3/4] style: remove backticks from filename autocomplete --- aider/io.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/aider/io.py b/aider/io.py index f4e3c2eb2..ebdb7492c 100644 --- a/aider/io.py +++ b/aider/io.py @@ -113,7 +113,7 @@ class AutoCompleter(Completer): candidates = self.words candidates.update(set(self.fname_to_rel_fnames)) - candidates = [(word, f"`{word}`") for word in candidates] + candidates = [(word, f"`{word}`" if word not in self.fname_to_rel_fnames else word) for word in candidates] last_word = words[-1] for word_match, word_insert in candidates: @@ -122,7 +122,7 @@ class AutoCompleter(Completer): if rel_fnames: for rel_fname in rel_fnames: yield Completion( - f"`{rel_fname}`", start_position=-len(last_word), display=rel_fname + rel_fname, start_position=-len(last_word), display=rel_fname ) else: yield Completion( From dc16bf6cda4caa0995d06095d348d86cb8927e5e Mon Sep 17 00:00:00 2001 From: "Paul Gauthier (aider)" Date: Wed, 21 Aug 2024 09:33:20 -0700 Subject: [PATCH 4/4] style: Format code using linter rules --- aider/io.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/aider/io.py b/aider/io.py index ebdb7492c..b0f76904c 100644 --- a/aider/io.py +++ b/aider/io.py @@ -113,7 +113,10 @@ class AutoCompleter(Completer): candidates = self.words candidates.update(set(self.fname_to_rel_fnames)) - candidates = [(word, f"`{word}`" if word not in self.fname_to_rel_fnames else word) for word in candidates] + candidates = [ + (word, f"`{word}`" if word not in self.fname_to_rel_fnames else word) + for word in candidates + ] last_word = words[-1] for word_match, word_insert in candidates: