问题
I had tons of gems on my local machine which I were installed before and after RVM, so I decided to wipe them all and reinstall. Everything seemed to go ok, except bundler:
gem list
.....
bundler (1.1.3, 1.0.22)
I don't know why 1.0.22 is still there, and I can't figure out how to get rid of it!
$ gem cleanup
Cleaning up installed gems...
Attempting to uninstall bundler-1.0.22
Unable to uninstall bundler-1.0.22:
Gem::InstallError: gem "bundler" is not installed
Clean Up Complete
$ gem uninstall bundler-1.0.22
INFO: gem "bundler-1.0.22" is not installed
UPDATE 1 Path info as requested by Andrew
/Users/brandon/.rvm/gems/ruby-1.9.3-p125-perf@global/gems/bundler-1.0.22/
回答1:
What's most likely happening is that the two versions of Bundler are installed in two different gemsets, one of which is inheriting from the other. 1.0.22
is probably installed in the global
gemset (rvm use @global
), or "root" gemset (rvm use <ruby_version>
). Once you're in the gemset that has 1.0.22
installed, you should be able to remove it with gem uninstall bundler
.
来源:https://stackoverflow.com/questions/10046321/updating-gems-on-my-mac-two-versions-of-bundler-installed