捆绑软件无法加载此类文件bundler-1.17.1 / exe / bundle [英] bundle cannot load such file bundler-1.17.1/exe/bundle

查看:83
本文介绍了捆绑软件无法加载此类文件bundler-1.17.1 / exe / bundle的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在FileUtils上遇到问题,必须卸载gem。完成此操作后,我进行了 gem更新--default ,并且一些gem已更新。这样就解决了FileUtils的问题,但是现在,捆绑器已死。

I had a problem with FileUtils and I had to uninstall the gem. After did this, I did gem update --default and some gems have been updated. That fixed my problem with FileUtils but now, bundler is dead.

如果我尝试 bundle info xxx ,我会收到这个信息错误:

If I try bundle info xxx I get this error:

Traceback (most recent call last):
    1: from /Users/robin/.gem/ruby/2.5.1/bin/bundle:23:in `<main>'
/Users/robin/.gem/ruby/2.5.1/bin/bundle:23:in `load': cannot load such file -- /Users/robin/.rubies/ruby-2.5.1/lib/ruby/gems/2.5.0/gems/bundler-1.17.1/exe/bundle (LoadError)

红宝石2.5.1p57
宝石2.7.7
Rails 5.2.1

ruby 2.5.1p57 gem 2.7.7 Rails 5.2.1

我正在使用chruby,并且我已经安装了Ruby 2.5.0和2.5.1。

I'm using chruby and I have Ruby 2.5.0 and 2.5.1 installed.

我尝试卸载bundler并重新安装它,但这并没有。

I tried to uninstall bundler and reinstall it but that doesn't work.

现在,即使我尝试 gem install bundler ,<$ c $中也没有目录c>〜/ .rubies / ruby​​-2.5.1 / lib / ruby​​ / gems / 2.5.0 / gems / 文件夹。

Now, even if I try gem install bundler, there's no directory in the ~/.rubies/ruby-2.5.1/lib/ruby/gems/2.5.0/gems/ folder.

但是,安装时没有任何错误:

However, I have no error when I install it:

gem install bundler
Successfully installed bundler-1.17.1
Parsing documentation for bundler-1.17.1
Done installing documentation for bundler after 3 seconds
1 gem installed

您有解决此问题的想法吗?

Do you have an idea to solve this problem?

编辑:

我可以在我的宝石列表中看到捆绑器:

I can see bundler in my gem list:

bundler(默认值:1.17) .1,默认值:1.16.2)

您可以看到,有两个默认版本...
我在gems中找不到任何捆绑程序目录,如果尝试卸载,则会显示以下消息:

And as you can see, there's two default versions... Also, I can't find any bundler directory in my gems and if I try to uninstall I get this message:

ERROR:  While executing gem ... (Gem::InstallError)
    gem "bundler" cannot be uninstalled because it is a default gem


推荐答案

尝试使用 gem原始捆绑器,它将gem恢复为原始状态。

Try gem pristine bundler, that restores the gem to it's original state.

这篇关于捆绑软件无法加载此类文件bundler-1.17.1 / exe / bundle的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆