mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-30 09:14:59 +00:00
feat: return edit command when input interrupted by file change
This commit is contained in:
parent
add3fa43c6
commit
8e873e7450
1 changed files with 5 additions and 0 deletions
|
@ -437,6 +437,11 @@ class InputOutput:
|
||||||
else:
|
else:
|
||||||
line = input(show)
|
line = input(show)
|
||||||
except (EOFError, KeyboardInterrupt):
|
except (EOFError, KeyboardInterrupt):
|
||||||
|
# Check if we were interrupted by a file change
|
||||||
|
if self.changed_files:
|
||||||
|
changed = self.changed_files
|
||||||
|
self.changed_files = None
|
||||||
|
return f"/edit {changed}" # Return an edit command for the changed file
|
||||||
return ""
|
return ""
|
||||||
except UnicodeEncodeError as err:
|
except UnicodeEncodeError as err:
|
||||||
self.tool_error(str(err))
|
self.tool_error(str(err))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue