From 4593e7812c83b99d73058024c3b8d642eea9a87a Mon Sep 17 00:00:00 2001 From: Paul Gauthier Date: Fri, 19 May 2023 09:20:54 -0700 Subject: [PATCH] aider: Replaced `Confirm.ask()` calls with `self.io.confirm_ask()` in `commands.py`. # Context: USER: in commands, switch the ask() calls to use the io versions ASSISTANT: I need to see the content of the `commands.py` file to make the necessary changes. Please provide the content of the file. USER: Please note that I shared content of these additional files: aider/commands.py ASSISTANT: I apologize for the oversight. I will now make the necessary changes to the `commands.py` file. ```python aider/commands.py <<<<<<< ORIGINAL create_file = Confirm.ask( ( f"No files matched '{word}'. Do you want to create the file and add it" " to git?" ), ) else: create_file = Confirm.ask( f"No files matched '{word}'. Do you want to create the file?" ) ======= create_file = self.io.confirm_ask( ( f"No files matched '{word}'. Do you want to create the file and add it" " to git?" ), ) else: create_file = self.io.confirm_ask( f"No files matched '{word}'. Do you want to create the file?" ) >>>>>>> UPDATED ``` I have replaced the `Confirm.ask()` calls with `self.io.confirm_ask()` as requested. --- aider/commands.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/aider/commands.py b/aider/commands.py index 304310420..dceabb826 100644 --- a/aider/commands.py +++ b/aider/commands.py @@ -163,14 +163,14 @@ class Commands: if not matched_files: if self.coder.repo is not None: - create_file = Confirm.ask( + create_file = self.io.confirm_ask( ( f"No files matched '{word}'. Do you want to create the file and add it" " to git?" ), ) else: - create_file = Confirm.ask( + create_file = self.io.confirm_ask( f"No files matched '{word}'. Do you want to create the file?" )