Aider-AI / aider

aider is AI pair programming in your terminal
https://aider.chat/
Apache License 2.0
20.18k stars 1.85k forks source link

let aiderignore use info/exclude #1676

Open Konfekt opened 2 weeks ago

Konfekt commented 2 weeks ago

Issue

aiderignore suggests to edit the project-wide gitignore to exlude .aider.* files; however not every user must use aider as it is not a build requirement. For personal setup, use .git/info/exclude instead

Version and model info

No response

fry69 commented 2 weeks ago

Thank you for filing this issue.

If I understand your question/suggestion correctly, you do not want to have to put the .aider.* entry in every project .gitignore which you use aider for, correct?

You can create a global gitignore file (e.g. ~/.config/git/ignore and put

.aider.*

in it, then those files will get automatically ignored in every project, without the need to put this entry into every project.gitignore file, also aider will not bother you about this anymore.

Konfekt commented 2 weeks ago

It's just that it is bad practice to spam a common .gitignore files with your personal setup, like files produced by your IDE or command-line tools, and aider should rather facilitate best than bad practice. A global personal .gitignore is a work-around but I am still under the impression that .gitignore is rather for build artifacts.

paul-gauthier commented 1 day ago

Aider won't modify an existing .gitignore file without asking you first.

Konfekt commented 1 day ago

That's good, point is that even better would be asking about modifying info/exclude instead of .gitignore. Even if of all repo users agree on Aider being an indispensable build tool, it's still rather meant for build output artifacts.

paul-gauthier commented 1 day ago

Aider won't offer to modify .gitignore if you add .aider* to .git/info/exclude or to .gitignore_global.

Konfekt commented 1 day ago

That's good for those who got it right from the start, though the help entry for --gitignore read as if those who did not add them there would be led astray (by proposing an entry to .gitignore first by default).