我正在使用带有 rails 2.3.5 的捆绑程序,我正在尝试确保一切正常,但是当我执行“rake db:migrate --trace”时,我得到了这个
** Invoke db:migrate (first_time)
** Invoke environment (first_time)
** Execute environment
rake aborted!
uninitialized constant SubdomainFu
/opt/local/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:443:in
load_missing_constant' /opt/local/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:80:in const_missing'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:92:in
const_missing' /Users/node/Projects/Race-RX/config/initializers /subdomain_config.rb:1 /opt/local/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:145:in load_without_new_constant_marking'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:145:in
load' /opt/local/lib/ruby/gems /1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:521:in new_constants_in'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:145:in
load' /opt/local/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb :622:in load_application_initializers'
/opt/local/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:621:in
each' /opt/local/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:621:in load_application_initializers'
/opt/local/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:176:in
process' /opt/local/lib/ruby/gems/1.8 /gems/rails-2.3.5/lib/initializer.rb:113:in send'
/opt/local/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:113:in
run' /Users/node/Projects/Race-RX/config/environment.rb:9 /opt/local/lib/ruby/site_ruby/1.8 /rubygems/custom_require.rb:31:在gem_original_require'
/opt/local/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
需要' /opt/local/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:156:in require'
/opt/local/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:521:in
new_constants_in' /opt/local/lib/ruby/gems/1.8/gems /activesupport-2.3.5/lib/active_support/dependencies.rb:156:in require'
/opt/local/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/tasks/misc.rake:4
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:636:in
call' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:636:inexecute'
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:631:in
每个'/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:631:in execute'
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:597:in
invoke_with_call_chain'/opt/local/lib/ruby/1.8 /monitor.rb:242 :in synchronize'
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:590:in
invoke_with_call_chain' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:607:in invoke_prerequisites'
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:604:in
each' /opt/local/lib/ruby/gems/1.8/gems /rake-0.8.7/lib/rake.rb:604:in invoke_prerequisites'
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:596:in
invoke_with_call_chain' /opt/local/lib/ruby/1.8/monitor.rb:242:in synchronize'
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:590:in
invoke_with_call_chain' /opt/local/lib/ruby/gems/1.8 /gems/rake-0.8.7/lib/rake.RB:583:在invoke'
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2051:in
invoke_task' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in top_level'
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in
each' /opt/local/lib/ruby/gems/1.8/gems/rake -0.8.7/lib/rake.rb:2029:in top_level'
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2068:in
standard_exception_handling '/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2023:in top_level'
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2001:in
run'/opt /local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2068:in standard_exception_handling'
/opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:1998:in
run' /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7 /bin/rake:31 /opt/local/bin/rake:19:inload'
/opt/local/bin/rake:19
我不知道是什么原因造成的。但是我做到了,但我的
需要“rubygems”需要“捆绑器”Bundler.setup
在我的 enviroment.rb 文件中,但这似乎不是问题所在。