gpt4 book ai didi

ruby-on-rails - bundler /设置(LoadError)

转载 作者:数据小太阳 更新时间:2023-10-29 06:26:15 26 4
gpt4 key购买 nike

我克隆了一个存储库并尝试运行 rails s。但是,我收到以下错误:

/Users/me/.rbenv/versions/1.9.3-p547/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require': cannot load such file -- bundler/setup (LoadError)
from /Users/me/.rbenv/versions/1.9.3-p547/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /Users/me/workspace/bindo/config/boot.rb:7:in `<top (required)>'
from /Users/me/.rbenv/versions/1.9.3-p547/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /Users/me/.rbenv/versions/1.9.3-p547/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from bin/rails:9:in `<main>'

我的 ruby 版本是:

ruby 1.9.3p547 (2014-05-14 revision 45962) [x86_64-darwin13.3.0]

我的 gem env 命令从此项目目录运行:

RubyGems Environment:
- RUBYGEMS VERSION: 1.8.23.2
- RUBY VERSION: 1.9.3 (2014-05-14 patchlevel 547) [x86_64-darwin13.3.0]
- INSTALLATION DIRECTORY: /usr/lib/ruby/gems/2.0.0
- RUBY EXECUTABLE: /Users/me/.rbenv/versions/1.9.3-p547/bin/ruby
- EXECUTABLE DIRECTORY: /usr/lib/ruby/gems/2.0.0/bin
- RUBYGEMS PLATFORMS:
- ruby
- x86_64-darwin-13
- GEM PATHS:
- /usr/lib/ruby/gems/2.0.0
- /Users/me/.gem/ruby/1.9.1
- /Users/me/.rbenv/versions/1.9.3-p547/lib/ruby/gems/1.9.1
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :benchmark => false
- :backtrace => false
- :bulk_threshold => 1000
- REMOTE SOURCES:
- http://rubygems.org/

我在 Stack Overflow 上读到这是一个路径错误,但是,我还不够熟悉,无法弄清楚要跟踪或更改什么才能使这项工作正常进行。我正在寻找,但我觉得我需要一些指导。

最佳答案

您可能缺少 bundler gem。

要使其运行(第一个命令可能需要使用 sudo 执行,具体取决于您的环境):

[sudo] gem install bundler
bundle install

关于ruby-on-rails - bundler /设置(LoadError),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26560725/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com