Gem :: InstallError:在gem清理期间,GEM_HOME中未安装gem-wrappers

时间:2014-11-26 03:46:26

标签: ruby-on-rails gem

如何避免gem清理特定错误。我在执行gem清理时看到以下错误。 Gem :: InstallError:GEM_HOME

中未安装gem-wrappers
gem cleanup
Cleaning up installed gems...
Attempting to uninstall gem-wrappers-1.2.4
Unable to uninstall gem-wrappers-1.2.4:
    Gem::InstallError: gem-wrappers is not installed in GEM_HOME, try:
    gem uninstall -i /home/ec2-user/.rvm/gems/ruby-2.1.2@global gem-wrappers
Attempting to uninstall gem-wrappers-1.2.4
Unable to uninstall gem-wrappers-1.2.4:
    Gem::InstallError: gem-wrappers is not installed in GEM_HOME, try:
    gem uninstall -i /home/ec2-user/.rvm/gems/ruby-2.1.2@global gem-wrappers
Clean Up Complete

2 个答案:

答案 0 :(得分:1)

cleanup命令从GEM_HOME中删除不需要满足依赖关系的旧版Gems。如果gem安装在GEM_PATH的其他位置,则cleanup命令不会删除它。

您可以尝试使用sudo gem cleanup

参考gem cleanup

另一个Cleanup gems

答案 1 :(得分:0)

在shell rc文件中添加以下一行。 (比如.bashrc,.zshrc,.profile)

$.each