Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions aider/coders/base_coder.py
Original file line number Diff line number Diff line change
Expand Up @@ -2216,7 +2216,7 @@ def allowed_to_edit(self, path):
# Seems unlikely that we needed to create the file, but it was
# actually already part of the repo.
# But let's only add if we need to, just to be safe.
if need_to_add:
if need_to_add and self.auto_commits:
self.repo.repo.git.add(full_path)

self.abs_fnames.add(full_path)
Expand All @@ -2230,7 +2230,7 @@ def allowed_to_edit(self, path):
self.io.tool_output(f"Skipping edits to {path}")
return

if need_to_add:
if need_to_add and self.auto_commits:
self.repo.repo.git.add(full_path)

self.abs_fnames.add(full_path)
Expand Down