[英]Rails 2.3 console refuses to come up after switching from rvm to rbenv
2年前,我將此Rails 2.3應用程序轉換為使用Bundler
,所以這不是問題。
script/console
腳本絕對拒絕加載<APP ROOT>/config/boot.rb
。
該文件將加載,如果我在irb
會話中的config
目錄中,或者來自:
require './config/boot'
但:
require 'config/boot'
不起作用。
rbenv
中是否存在某種導致這些問題的路徑rbenv
? 昨晚15分鍾的工作量使我的生產系統停機了8個小時。 它一定很簡單。
同樣,請注意,此應用程序已與Bundler一起使用了2年。 從rvm
到rbenv
的切換顯然導致了這一點。
我很久以前已經按照這些說明進行操作,並確認它們仍然有效: http : //bundler.io/v1.3/rails23.html
*腳本/控制台*
#!/usr/bin/env ruby
require File.dirname(__FILE__) + '/../config/boot'
require 'commands/console'
注意:還注意到vendor/plugins
加載任何內容。
整個錯誤 /home/myapp/.rbenv/versions/2.1.5/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in require': cannot load such file -- script/../config/boot (LoadError) from /home/myapp/.rbenv/versions/2.1.5/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in
require'中的require': cannot load such file -- script/../config/boot (LoadError) from /home/myapp/.rbenv/versions/2.1.5/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in
來自腳本/控制台:2:in '
不起作用:
script/server
可以工作:
./script/server
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.