If I do sudo gem uninstall rails -v 3.0.0.beta3
, it uninstalls rails but leaves the beta3 versions of activerecord, actionmailer, etc. How do I completely uninstall rails 3.0.0.beta3 and all its dependencies automatically? I would like a clean slate for the RC and final releases.
views:
293answers:
3
A:
you can't do it automatically unless you write your own script wrapper around the gem uninstall command
just manually do gem uninstall on the other files like activerecord, activesupport, etc...
cpjolicoeur
2010-06-10 18:00:41
+1
A:
$ gem list
...
$ sudo gem uninstall {gem-you-don't-want} {version-you-don't-want}
$ {rinse-and-repeat}
Justice
2010-06-10 18:03:35
well sure, if you want to do it the hard way! i was hoping dependencies also worked for UNinstall :)
Mark Richman
2010-06-10 19:27:38
@Mark Richman: RubyGems doesn't track which gems were installed manually and which ones were installed automatically as dependencies. Therefore, it simply *cannot* know which ones are still needed.
Jörg W Mittag
2010-06-10 23:16:58
+1
A:
If your situation is that you have installed beta 4 and want to get rid of beta 3, you can simply run
gem cleanup
which removes all but the latest version of all your gems (wiping out beta 3 and leaving you with beta 4).
thorncp
2010-06-10 19:43:53