diff options
-rw-r--r-- | railties/environments/boot.rb | 12 | ||||
-rwxr-xr-x | railties/fresh_rakefile | 1 |
2 files changed, 7 insertions, 6 deletions
diff --git a/railties/environments/boot.rb b/railties/environments/boot.rb index 7f30e829a9..1df433a7eb 100644 --- a/railties/environments/boot.rb +++ b/railties/environments/boot.rb @@ -1,8 +1,10 @@ -RAILS_ROOT = File.join(File.dirname(__FILE__), '..') +RAILS_ROOT = File.join(File.dirname(__FILE__), '..') unless defined?(RAILS_ROOT) -unless File.directory?("#{RAILS_ROOT}/vendor/rails") +if File.directory?("#{RAILS_ROOT}/vendor/rails") + require "#{RAILS_ROOT}/vendor/rails/railties/lib/initializer" +else require 'rubygems' require 'initializer' -else - require "#{RAILS_ROOT}/vendor/rails/railties/lib/initializer" -end
\ No newline at end of file +end + +Rails::Initializer.run(:set_load_path)
\ No newline at end of file diff --git a/railties/fresh_rakefile b/railties/fresh_rakefile index 34815400d7..cffd19f0c1 100755 --- a/railties/fresh_rakefile +++ b/railties/fresh_rakefile @@ -2,7 +2,6 @@ # for example lib/tasks/switchtower.rake, and they will automatically be available to Rake. require(File.join(File.dirname(__FILE__), 'config', 'boot')) -Rails::Initializer.run(:set_load_path) require 'rake' require 'rake/testtask' |