mirror of
https://github.com/Aider-AI/aider.git
synced 2025-05-29 08:44:59 +00:00
fix: Handle OSError when resolving config file path
This commit is contained in:
parent
12578c0388
commit
1a4ef0f532
2 changed files with 8 additions and 1 deletions
|
@ -347,7 +347,12 @@ def main(argv=None, input=None, output=None, force_git_root=None, return_coder=F
|
|||
|
||||
conf_fname = Path(".aider.conf.yml")
|
||||
|
||||
default_config_files = [conf_fname.resolve()] # CWD
|
||||
default_config_files = []
|
||||
try:
|
||||
default_config_files += [conf_fname.resolve()] # CWD
|
||||
except OSError:
|
||||
pass
|
||||
|
||||
if git_root:
|
||||
git_conf = Path(git_root) / conf_fname # git root
|
||||
if git_conf not in default_config_files:
|
||||
|
|
|
@ -22,6 +22,8 @@ Reply only with the one-line commit message, without any additional text, explan
|
|||
or line breaks.
|
||||
"""
|
||||
|
||||
print(commit_system)
|
||||
|
||||
# COMMANDS
|
||||
undo_command_reply = (
|
||||
"I did `git reset --hard HEAD~1` to discard the last edits. Please wait for further"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue