运行“bundle install”失败并要求我运行“bundle install”

2024-06-24

事实上,当从我从 git 存储库克隆的现有 Rails 应用程序内部运行时,所有与 gem 相关的命令都会导致相同的错误消息。

$ bundle install
Could not find tzinfo-0.3.27 in any of the sources
Run `bundle install` to install missing gems.

$ gem list
Could not find tzinfo-0.3.27 in any of the sources
Run `bundle install` to install missing gems.

$ bundle update
Could not find tzinfo-0.3.27 in any of the sources
Run `bundle install` to install missing gems.

$ rails -v
Could not find tzinfo-0.3.27 in any of the sources
Run `bundle install` to install missing gems.

我以为我已经安装了 Rails...(以下命令是从应用程序目录外部运行的):

$ rails -v
Rails 3.0.3

$ ruby -v
ruby 1.9.2p290 (2011-07-09 revision 32553) [x86_64-darwin11.0.0]

知道“捆绑安装”告诉我运行“捆绑安装”是怎么回事吗?


我退出了我的应用程序目录并手动执行

sudo gem install tzinfo -v 0.3.27

但是再次进入我的应用程序目录并尝试“捆绑安装”时......

$ bundle install
Could not find polyglot-0.3.1 in any of the sources
Run `bundle install` to install missing gems.

所以我退出了应用程序目录,做了

sudo gem install polyglot -v 0.3.1

“捆绑安装”现已产生

$ bundle install
Could not find treetop-1.4.9 in any of the sources
Run `bundle install` to install missing gems.

为什么我必须手动安装所有这些过去不需要的随机宝石? (新的开发环境)。有人知道我在我的环境中可能设置了错误吗?


好吧我猜我修好了..

对于正在运行的宝石bundle install抱怨当从应用程序目录内部运行时,我通过进入应用程序目录之外并执行以下操作来安装它们sudo gem install [gem]逐个。正在做bundle install --gemfile=myApp/Gemfile还安装了一些缺失的宝石。

我不知道为什么我不能跑bundle install从应用程序目录内部...蹩脚。

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

运行“bundle install”失败并要求我运行“bundle install” 的相关文章

随机推荐