eclipse: “re-indexing repository workspace” or “Computing Git status for repository workspace”

一世执手 提交于 2020-01-13 10:16:30

问题


I am using eclipse Juno, and yesterday I noticed my computer was getting very hot. I checked the CPU usage to see it was at 100%. Eclipse was the culprit, busy "re-indexing repository workspace". When after half an hour it hadn't finished and my machine was nearly melting, I searched and found these similar problems:

Re-indexing repository loop - not Maven

Eclipse hangs on "Re-indexing (fully) repository {username}"

Thing is I'm not using git. And by the sounds of things I don't want to since it's going to eat all my CPU. I removed ~/git, deleted a project I have which uses git, checked for any files under ~/.git, removed egit and jgit from eclipse plugins, and it's still happening.

I can stop the process each time, but now it seems unable to build the workspace.

So I decided to upgrade to Kepler, and now I have a similar problem with a different message:

"Computing Git status for repository workspace"

Again it's eating 100% of my CPU and threatening to set fire to my desk.

And I don't even have any open git projects.

How do I stop this stupid thing? Every time I stop the process, but if I then try to clean rebuild or open a project, it starts up again.


回答1:


This was an old bug in EGit where it automatically found the .git in your home directory and then scanned all the files in the home directory. It has been fixed in newer versions of EGit.

But you may still have the repository configured, even after you upgraded. Do the following:

  1. Open the Git Repositories view
  2. Find the repository that causes the problem
  3. In the context menu, select Remove Repository from View

Then restart Eclipse.




回答2:


In my case, this is my solution

Ubuntu 16.04

rm -r workspace/.metadata/.plugins/org.eclipse.core.resources/.projects/*/org.eclipse.egit.core
rm -r workspace/.metadata/.plugins/org.eclipse.core.resources/.projects/*/.indexes/properties.index


来源:https://stackoverflow.com/questions/22397074/eclipse-re-indexing-repository-workspace-or-computing-git-status-for-reposit

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!