Bundler throws No Such file or directory for gem install

和自甴很熟 提交于 2019-12-06 06:31:36

问题


In Gemfile,

gem "backup", :git => "git://github.com/tenmiles/backup.git", :ref => "develop"

n local and in staging, bundle install did finish successfully. In production, when bundle install --deployment happens, bundler throws this error

Using backup (3.0.19) from git://github.com/tenmiles/backup.git (at develop)
/usr/local/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:365:in `initialize': No such file or directory - /home/anand/public_html/myapp/releases/20111113170352/vendor/bundle/ruby/1.9.1/bundler/gems/gems/backup-3.0.19/bin/backup (Errno::ENOENT)

I checked in /home/anand/public_html/myapp/releases/20111113170352/vendor/bundle/ruby/1.9.1/bundler/gems/gems/ and backup-150fb5168ebe is there! Its a gem installed via git. why is bundler looking for backup-3.0.19. How can I refresh backup gem and ask bundler to re install the gem from scratch.

Please help


回答1:


Try this http://raflabs.com/blogs/silence-is-foo/2010/07/19/installing-a-gem-fork-from-github-source/ U can install the gem into your gem set by the method mentioned in there




回答2:


I had this issue with 1.0.10, but when I updated the servers to bundler 1.0.21 the problem went away.




回答3:


i have the some problem with current spork. If you specify a version it should work

gem "backup", '1.0', :git => "git://github.com/tenmiles/backup.git"

it fixed it for me



来源:https://stackoverflow.com/questions/8113258/bundler-throws-no-such-file-or-directory-for-gem-install

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!