I switched to a new company a few weeks ago and have since been pulling my hair out constantly at the horrible, horrible performance RubyMine has been giving me with my company's massive, although fairly well broken up, codebase. It would generally start after starting/stopping rubymine a few times, and then I would notice it sucking the life out of my harddrive while it did absolutely nothing except respond slowly. No it's not indexing, no it's not inspecting, all it's doing at this point is making me slowly die inside. It even got to the point where if I quit RubyMine while it was sludging, when it started back up it would continue sludging exactly where it left off and never stop. This happened many times a day and was extremely embarassing as my apple-wielding coworkers scratched their heads and wondered why I didn't upgrade my IDE.
Since it persisted beyond shutting it down I tried clearing out my ~/.RubyMine20/ directory and letting it recreate it... This made it run like new with no noticable slowdowns in sight, aside from the initial re-indexing. I soon found it was the ~/.RubyMine20/system/ directory that was holding whatever state was causing it to sludge, so this is what I did to fix it as a long term but effective solution:
In a nutshell, the key is that you run this script instead of the rubymine.sh script, the script copies over a clean version of the system folder, then starts rubymine all fresh and new every time without you having to think about it. If rubymine starts slowing down as it inevitably will, just close it and run the script again and you're good to go.
- delete the ~/.RubyMine20/ directory (NOTE: you might want to save your ~/.RubyMine20/config/ if you care about your shortcuts and configurations... you might be able to only delete the system directory, this is just what I did)
- start RubyMine
- open your project as if you were about to start working and wait for RubyMine to settle down
- close RubyMine politely
- cp ~/.RubyMine20/system ~/.RubyMine20/system-clean
drop the attached script in your rubymine_home/bin/ and chmod a+x it... I set it so you have to adjust the script for it to run, put a few comments in there... Be -extremely- careful with it, it contains an rm -rf
Let me know if you have any questions or if the script doesn't make any sense or if you think my method sucks and you do it better, because you probably can.