Last active
September 24, 2015 04:57
-
-
Save mmontalvo/670558 to your computer and use it in GitHub Desktop.
List of useful commands
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# To uninstall ALL gems | |
for i in `gem list --no-versions`; do gem uninstall -aIx $i; done |
For Ruby 2.0
(from http://stackoverflow.com/questions/15100496/uninstalling-all-gems-ruby-2-0-0)
for i in gem list --no-versions
; do gem uninstall -aIx $i; done
StackOverflow to the rescue! (http://stackoverflow.com/questions/8095209/uninstall-all-installed-gems-in-osx)
for i in gem list --no-versions
; do gem uninstall -aIx $i; done
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
A better solution (without crashes from the different versions problem):
gem list | cut -d" " -f1 | xargs gem uninstall -aIx
(from http://www.arailsdemo.com/posts/18 and originally taken from http://geekystuff.net/2009/1/14/remove-all-ruby-gems)