diff options
author | Pratik Naik <pratiknaik@gmail.com> | 2010-01-19 13:40:26 +0530 |
---|---|---|
committer | Pratik Naik <pratiknaik@gmail.com> | 2010-01-19 13:40:26 +0530 |
commit | c71120e29caddda295c133adfb279870733a3f81 (patch) | |
tree | da81981de36bc146c36cae3bc73cb5020ba05919 /railties/lib/generators/rails/app/templates/config/boot.rb | |
parent | 087b67805e3785159cb4da524ad37782bd182b93 (diff) | |
parent | 71d67fc6bd504956bce66e274e6228dd00a814c1 (diff) | |
download | rails-c71120e29caddda295c133adfb279870733a3f81.tar.gz rails-c71120e29caddda295c133adfb279870733a3f81.tar.bz2 rails-c71120e29caddda295c133adfb279870733a3f81.zip |
Merge remote branch 'mainstream/master'
Diffstat (limited to 'railties/lib/generators/rails/app/templates/config/boot.rb')
-rw-r--r-- | railties/lib/generators/rails/app/templates/config/boot.rb | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/railties/lib/generators/rails/app/templates/config/boot.rb b/railties/lib/generators/rails/app/templates/config/boot.rb new file mode 100644 index 0000000000..466e1e50ec --- /dev/null +++ b/railties/lib/generators/rails/app/templates/config/boot.rb @@ -0,0 +1,36 @@ +# Use Bundler (preferred) +environment = File.expand_path('../../vendor/gems/environment', __FILE__) +if File.exist?("#{environment}.rb") + require environment + +# Use 2.x style vendor/rails and RubyGems +else + vendor_rails = File.expand_path('../../vendor/rails', __FILE__) + if File.exist?(vendor_rails) + Dir["#{vendor_rails}/*/lib"].each { |path| $:.unshift(path) } + end + + require 'rubygems' +end + +<% unless options[:skip_activerecord] -%> +require 'rails/all' + +# To pick the frameworks you want, remove 'require "rails/all"' +# and list the framework railties that you want: +# +# require "active_model/railtie" +# require "active_record/railtie" +# require "action_controller/railtie" +# require "action_view/railtie" +# require "action_mailer/railtie" +# require "active_resource/railtie" +<% else -%> +# Pick the frameworks you want: +# require "active_record/railtie" +require "active_model/railtie" +require "action_controller/railtie" +require "action_view/railtie" +require "action_mailer/railtie" +require "active_resource/railtie" +<% end -%>
\ No newline at end of file |