为什么我的服务器不能简单地使用rails s
启动→ rails s
/usr/local/var/rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/dependency.rb:298:in `to_specs': Could not find 'minitest' (~> 5.1) - did find: [minitest-4.7.5] (Gem::LoadError)
→ bundle exec rails s
=> Booting Thin
=> Rails 4.0.3 application starting in development on http://0.0.0.0:3000
=> Run `rails server -h` for more startup options
=> Ctrl-C to shutdown server
Thin web server (v1.6.1 codename Death Proof)
Maximum connections set to 1024
Listening on 0.0.0.0:3000, CTRL+C to stop
答案 0 :(得分:6)
我必须执行以下操作,现在它可以正常工作。
→ bundle clean --force
→ bundle update
→ rails s
=> Booting Thin
=> Rails 4.0.3 application starting in development on http://0.0.0.0:3000
=> Run `rails server -h` for more startup options
=> Ctrl-C to shutdown server
Thin web server (v1.6.1 codename Death Proof)
Maximum connections set to 1024
Listening on 0.0.0.0:3000, CTRL+C to stop
答案 1 :(得分:1)
好像在Gemfile
你需要minitest (~> 5.1)
但您系统上的当前版本为4.7.5
跑
bundle update minitest
它会更新minitest
版本。