gpt4 book ai didi

ruby-on-rails - Rails 控制台无法加载, "Could not find gem ' rails (= 3.0.0.beta3) ruby​​"

转载 作者:太空宇宙 更新时间:2023-11-03 16:34:07 24 4
gpt4 key购买 nike

我在 Rails 控制台中输入开始工作并收到以下错误:

MacBook-Pro:blog agreiner$ rails console
/Users/agreiner/.rvm/gems/ruby-1.9.3-p194/gems/bundler-1.1.3/lib/bundler/resolver.rb:287:in `resolve': Could not find gem 'rails (= 3.0.0.beta3) ruby' in the gems available on this machine. (Bundler::GemNotFound)
from /Users/agreiner/.rvm/gems/ruby-1.9.3-p194/gems/bundler 1.1.3/lib/bundler/resolver.rb:161:in `start'
from /Users/agreiner/.rvm/gems/ruby-1.9.3-p194/gems/bundler 1.1.3/lib/bundler/resolver.rb:128:in `block in resolve'
from /Users/agreiner/.rvm/gems/ruby-1.9.3-p194/gems/bundler-1.1.3/lib/bundler/resolver.rb:127:in `catch'
from /Users/agreiner/.rvm/gems/ruby-1.9.3-p194/gems/bundler-1.1.3/lib/bundler/resolver.rb:127:in `resolve'
from /Users/agreiner/.rvm/gems/ruby-1.9.3-p194/gems/bundler-1.1.3/lib/bundler/definition.rb:192:in `resolve'
from /Users/agreiner/.rvm/gems/ruby-1.9.3-p194/gems/bundler 1.1.3/lib/bundler/definition.rb:127:in `specs'
from /Users/agreiner/.rvm/gems/ruby-1.9.3-p194/gems/bundler-1.1.3/lib/bundler/definition.rb:161:in `requested_specs'
from /Users/agreiner/.rvm/gems/ruby-1.9.3-p194/gems/bundler-1.1.3/lib/bundler/environment.rb:23:in `requested_specs'
from /Users/agreiner/.rvm/gems/ruby-1.9.3-p194/gems/bundler 1.1.3/lib/bundler/runtime.rb:11:in `setup'
from /Users/agreiner/.rvm/gems/ruby-1.9.3-p194/gems/bundler-1.1.3/lib/bundler.rb:107:in `setup'
from /Users/agreiner/blog/config/boot.rb:5:in `<top (required)>'
from /Users/agreiner/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /Users/agreiner/.rvm/rubies/ruby 1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require' from >script/rails:8:in `<main>'

几天前我开始使用 Rails,所以我分析错误的能力仅限于我的 google 能力。我还没有找到关于 Could not find gem 'rails(=3.0.0beta3) ruby​​

的任何信息

谁能指出我正确的方向?

最佳答案

看起来 rails gem 曾经安装过,但后来只卸载了一部分,或者安装了,但安装在一个意想不到的位置。第一步是尝试重新安装。我不确定您使用的是系统 ruby​​,还是通过 rvm/ruby-build 安装的系统,因此很难提供比这更多的建议。

关于ruby-on-rails - Rails 控制台无法加载, "Could not find gem ' rails (= 3.0.0.beta3) ruby​​",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10576048/

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