Merb、Bundler、RVM 和 1.9.1 = 无法找到 Gemfile (Bundler::GemfileNotFound)
任何人都可以建议如何解决此问题(Ubuntu 9.10):
/home/chris/.rvm/gems/ruby-1.9.1-p378/gems/bundler-0.9.26/lib/bundler/shared_helpers.rb:42:in `default_gemfile': Could not locate Gemfile (Bundler::GemfileNotFound)
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/bundler-0.9.26/lib/bundler/shared_helpers.rb:51:in `env_file'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/bundler-0.9.26/lib/bundler.rb:143:in `env_file'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/bundler-0.9.26/lib/bundler.rb:174:in `update_env_file?'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/bundler-0.9.26/lib/bundler.rb:95:in `load'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/bundler-0.9.26/lib/bundler.rb:76:in `gem_setup'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/merb-core-1.1.2/bin/merb:10:in `rescue in <top (required)>'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/merb-core-1.1.2/bin/merb:3:in `<top (required)>'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/bin/merb:19:in `load'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/bin/merb:19:in `<main>'
谢谢
Chris
更新
我非常努力地想让它发挥作用。最终我又回到了 merb-core 1.0.12,效果很好。
Can anyone suggest how to fix this (Ubuntu 9.10):
/home/chris/.rvm/gems/ruby-1.9.1-p378/gems/bundler-0.9.26/lib/bundler/shared_helpers.rb:42:in `default_gemfile': Could not locate Gemfile (Bundler::GemfileNotFound)
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/bundler-0.9.26/lib/bundler/shared_helpers.rb:51:in `env_file'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/bundler-0.9.26/lib/bundler.rb:143:in `env_file'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/bundler-0.9.26/lib/bundler.rb:174:in `update_env_file?'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/bundler-0.9.26/lib/bundler.rb:95:in `load'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/bundler-0.9.26/lib/bundler.rb:76:in `gem_setup'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/merb-core-1.1.2/bin/merb:10:in `rescue in <top (required)>'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/gems/merb-core-1.1.2/bin/merb:3:in `<top (required)>'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/bin/merb:19:in `load'
from /home/chris/.rvm/gems/ruby-1.9.1-p378/bin/merb:19:in `<main>'
Thank
Chris
Update
I tried really hard to get this to work. Eventually I fell back to merb-core 1.0.12 and that worked fine.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
解决方案
我需要为我的应用程序编写一个 Gemfile 并将其放入应用程序的根目录中。
我升级了太多版本的 Merb!我的应用程序是一个扁平的 Rack 应用程序,最初是使用旧版本的 Merb 开发的。它没有(或不需要)Gemfile。当我针对最新的 Merb 运行它时,抛出了错误。如果它说“我找不到适合您的应用程序的 Gemfile”,那就更好了。
我运行了
merb-gen
来获取基本的 Gemfile,并根据自己的要求更新了它。希望对某人有帮助!
Solution
I needed to write a Gemfile for my application and drop it into the root directory for the app.
I was upgrading across too many versions of Merb! My application was a flat, Rack application originally developed with a much older version of Merb. It didn't have (or need) a Gemfile. When I ran it against the latest Merb, the error was thrown. It would have been better if it said 'I can't find the Gemfile for your application'
I ran
merb-gen
to get a basic Gemfile and updated it with my own requirements.Hope that helps someone!
看起来您需要一个 gem,以及构建该 gem 的依赖项。
这可能有帮助,它帮助了我: postgres
(在Ubuntu上)
sudo apt-get install ruby-full build-essential postgresql-server-dev-8.3(或8.4)
sudo gem install postgres heroku 使用 postgresql-server-dev-8.3 。
如果您要部署到 postgresql-server-dev-8.3,则
Looks like you need a gem, and a dependency to build that gem.
This might help, it helped me: postgres
(on ubuntu)
sudo apt-get install ruby-full build-essential postgresql-server-dev-8.3 (or 8.4)
sudo gem install postgres
heroku uses postgresql-server-dev-8.3 if you're deploying there.