diff options
Diffstat (limited to 'railties/lib/rails')
-rw-r--r-- | railties/lib/rails/engine.rb | 5 | ||||
-rw-r--r-- | railties/lib/rails/generators/app_base.rb | 9 | ||||
-rw-r--r-- | railties/lib/rails/generators/rails/app/templates/app/assets/stylesheets/application.css | 2 |
3 files changed, 9 insertions, 7 deletions
diff --git a/railties/lib/rails/engine.rb b/railties/lib/rails/engine.rb index ef48bc4f94..47856c87c6 100644 --- a/railties/lib/rails/engine.rb +++ b/railties/lib/rails/engine.rb @@ -567,8 +567,9 @@ module Rails end initializer :load_environment_config, :before => :load_environment_hook, :group => :all do - environment = paths["config/environments"].existent.first - require environment if environment + paths["config/environments"].existent.each do |environment| + require environment + end end initializer :append_assets_path, :group => :all do |app| diff --git a/railties/lib/rails/generators/app_base.rb b/railties/lib/rails/generators/app_base.rb index d661c62148..10ad475d55 100644 --- a/railties/lib/rails/generators/app_base.rb +++ b/railties/lib/rails/generators/app_base.rb @@ -249,13 +249,14 @@ module Rails # We unset temporary bundler variables to load proper bundler and Gemfile. # # Thanks to James Tucker for the Gem tricks involved in this call. + _bundle_command = Gem.bin_path('bundler', 'bundle') - bundle_gemfile, rubyopt = ENV['BUNDLE_GEMFILE'], ENV['RUBYOPT'] - ENV['BUNDLE_GEMFILE'], ENV['RUBYOPT'] = "", "" + bundle_bin_path, bundle_gemfile, rubyopt = ENV['BUNDLE_BIN_PATH'], ENV['BUNDLE_GEMFILE'], ENV['RUBYOPT'] + ENV['BUNDLE_BIN_PATH'], ENV['BUNDLE_GEMFILE'], ENV['RUBYOPT'] = "", "", "" - print `"#{Gem.ruby}" "#{Gem.bin_path('bundler', 'bundle')}" #{command}` + print `"#{Gem.ruby}" "#{_bundle_command}" #{command}` - ENV['BUNDLE_GEMFILE'], ENV['RUBYOPT'] = bundle_gemfile, rubyopt + ENV['BUNDLE_BIN_PATH'], ENV['BUNDLE_GEMFILE'], ENV['RUBYOPT'] = bundle_bin_path, bundle_gemfile, rubyopt end def run_bundle diff --git a/railties/lib/rails/generators/rails/app/templates/app/assets/stylesheets/application.css b/railties/lib/rails/generators/rails/app/templates/app/assets/stylesheets/application.css index 3b5cc6648e..3192ec897b 100644 --- a/railties/lib/rails/generators/rails/app/templates/app/assets/stylesheets/application.css +++ b/railties/lib/rails/generators/rails/app/templates/app/assets/stylesheets/application.css @@ -10,4 +10,4 @@ * *= require_self *= require_tree . -*/ + */ |