Shorthand to clean up installed Rubygems (but don’t cleanup Rails)
I trimmed my installed Rubygems on my local development machine. The command “
sudo gem cleanup
” is just for that.
Only problem: What about my older Rails apps that require a specific version of Rails, ActiveRecord, etc.?
My solution:
gem list –no-versions | grep -v “^active” | grep -v “^action” | grep -v “^rails$” | xargs sudo gem cleanup {}
Any suggestions on how to make it even simpler?

June 19th, 2009 at 15:21 (GMT-1)
No suggestions – I’ve been looking for this solution for quite a while. Thanks! :) (I hope I’ll be more helpful someday:P)