Git integration brings up thousands of files


I have Atom 1.18.0 installed on Mac OS X 10.12.5.

Whenever I open a project folder, Git integration comes up with over a hundred thousand files listed, severely slowing down Atom. The files listed is truncated to the first 1000 items but includes things that begin with .Trash, for instance, stuff which is definitely not in the folder I opened. The only way I have found to be able to use Atom without it lagging to unusable levels is to disable the github package.


I have tried completely deleting both ~/.atom and ~/Library/Application Support/Atom. The issue persists.


Nevermind. I figured it out. For some reason my home directory was a git repo.


Do you mind sharing how you changed this? I am experiencing the same issue and it’s driving me crazy. I changed the path under Preferences > Core > Project Home but it’s still bringing up those 100,000+ unstaged files.


Open a terminal. See if ~/.git exists.

User:~$ cd .git

If it does, then go back and delete the folder:

User:.git$ cd ..
User:~$ rm -rf .git

That should fix the issue. I don’t know how important that git repo is, though, or why it should exist, so I don’t know what the ramifications are of deleting it.

You can also view every .git folder on your computer by using:

User:~$ sudo find / -name ".git"


Just to reference an existing issue in case anyone else comes across this post:

Slowness/high CPU usage resulting from a git repo in your home directory (which is most likely done accidentally) is an example of where this can come up.

If you didn’t do it on purpose you can remove the .git directory as described by @trekky0623.


I am seeing this as well when working on a project on a remote server that i have mapped to a Windows directory. It shows every file as if I have yet to make my initial commit on the repo. Additionally, in the tree-view, most files show as having been changed when none of them have. I do not seem to have this problem with a local project.


On a side note, the Git version on our server is Not sure if that would have an impact.


Anyone else seeing this? I am still having this issue.


Your issue is different from what everybody else has been experiencing, since you’re using a remote server and not on Mac.

What happens if you navigate to the mapped directory and use git status?


Interesting. Doing as you suggest supports what I am seeing in Atom in that it is showing all files as being unstaged for commit. Maybe my workflow is not the properway of working on such files. Should I be cloning it locally instead?


I did some further searching and it seems this is related to git/samba and windows vs. linux. I found this post!topic/msysgit/0TAtBUh9VYU that references the same problem. By updating core.fileMode to false on my repo it does seem to have fixed my problem of showing every file as changed. Does anyone have any recommendations for or against this?


A rule that I’ve found goes most of the way to solving most problems within Atom is that most functions not related to the operation of a text editor are outsourced to external programs. Working on that premise, it’s usually not hard to find out what command is being executed behind the scenes and do that yourself in order to observe the raw output. Most of the time, the results of that one action give me the information I need to come to a solution.

Should I be cloning it locally instead?

There would certainly be fewer variables at play. As a hobbyist, I always clone all my repos locally, even when the main home of the project is on another machine. I have one project that’s cloned onto four different machines (three physical, one virtual) and the only time I didn’t keep them synced was when I needed to troubleshoot a bug (so I had two post-bug environments and two pre-bug environments and I was tweaking files remotely).

By updating core.fileMode to false on my repo it does seem to have fixed my problem of showing every file as changed. Does anyone have any recommendations for or against this?

I don’t know enough to be informed about this.