diff options
Diffstat (limited to 'railties/lib')
9 files changed, 17 insertions, 13 deletions
diff --git a/railties/lib/rails/commands/runner.rb b/railties/lib/rails/commands/runner.rb index 2b77d5d387..dd2ee5639e 100644 --- a/railties/lib/rails/commands/runner.rb +++ b/railties/lib/rails/commands/runner.rb @@ -50,5 +50,5 @@ elsif File.exist?(code_or_file) $0 = code_or_file Kernel.load code_or_file else - eval(code_or_file) + eval(code_or_file, binding, __FILE__, __LINE__) end diff --git a/railties/lib/rails/engine.rb b/railties/lib/rails/engine.rb index 3f109debdc..54a0f1c002 100644 --- a/railties/lib/rails/engine.rb +++ b/railties/lib/rails/engine.rb @@ -260,7 +260,7 @@ module Rails # # class FooController < ApplicationController # def index - # my_engine.root_url #=> /my_engine/ + # my_engine.root_url # => /my_engine/ # end # end # @@ -269,7 +269,7 @@ module Rails # module MyEngine # class BarController # def index - # main_app.foo_path #=> /foo + # main_app.foo_path # => /foo # end # end # end diff --git a/railties/lib/rails/generators/app_base.rb b/railties/lib/rails/generators/app_base.rb index d79cf2b2f0..2022b4ed3d 100644 --- a/railties/lib/rails/generators/app_base.rb +++ b/railties/lib/rails/generators/app_base.rb @@ -113,7 +113,7 @@ module Rails end def add_gem_entry_filter - @gem_filter = lambda { |next_filter,entry| + @gem_filter = lambda { |next_filter, entry| yield(entry) && next_filter.call(entry) }.curry[@gem_filter] end diff --git a/railties/lib/rails/generators/rails/app/templates/app/assets/javascripts/application.js.tt b/railties/lib/rails/generators/rails/app/templates/app/assets/javascripts/application.js.tt index 8b91313e51..07ea09cdbd 100644 --- a/railties/lib/rails/generators/rails/app/templates/app/assets/javascripts/application.js.tt +++ b/railties/lib/rails/generators/rails/app/templates/app/assets/javascripts/application.js.tt @@ -13,6 +13,8 @@ <% unless options[:skip_javascript] -%> //= require <%= options[:javascript] %> //= require <%= options[:javascript] %>_ujs +<% if gemfile_entries.any? { |m| m.name == "turbolinks" } -%> //= require turbolinks <% end -%> +<% end -%> //= require_tree . diff --git a/railties/lib/rails/generators/rails/app/templates/public/404.html b/railties/lib/rails/generators/rails/app/templates/public/404.html index 7d99be2ecf..b612547fc2 100644 --- a/railties/lib/rails/generators/rails/app/templates/public/404.html +++ b/railties/lib/rails/generators/rails/app/templates/public/404.html @@ -58,10 +58,10 @@ <!-- This file lives in public/404.html --> <div class="dialog"> <div> - <h1>The page you were looking for doesn't exist.</h1> - <p>You may have mistyped the address or the page may have moved.</p> + <h1>The page you were looking for doesn't exist.</h1> + <p>You may have mistyped the address or the page may have moved.</p> </div> - <p>If you are the application owner check the logs for more information.</p> + <p>If you are the application owner check the logs for more information.</p> </div> </body> </html> diff --git a/railties/lib/rails/generators/rails/app/templates/public/422.html b/railties/lib/rails/generators/rails/app/templates/public/422.html index ee18eeb10c..a21f82b3bd 100644 --- a/railties/lib/rails/generators/rails/app/templates/public/422.html +++ b/railties/lib/rails/generators/rails/app/templates/public/422.html @@ -58,10 +58,10 @@ <!-- This file lives in public/422.html --> <div class="dialog"> <div> - <h1>The change you wanted was rejected.</h1> - <p>Maybe you tried to change something you didn't have access to.</p> + <h1>The change you wanted was rejected.</h1> + <p>Maybe you tried to change something you didn't have access to.</p> </div> - <p>If you are the application owner check the logs for more information.</p> + <p>If you are the application owner check the logs for more information.</p> </div> </body> </html> diff --git a/railties/lib/rails/generators/rails/app/templates/public/500.html b/railties/lib/rails/generators/rails/app/templates/public/500.html index e4161c3ce5..061abc587d 100644 --- a/railties/lib/rails/generators/rails/app/templates/public/500.html +++ b/railties/lib/rails/generators/rails/app/templates/public/500.html @@ -58,9 +58,9 @@ <!-- This file lives in public/500.html --> <div class="dialog"> <div> - <h1>We're sorry, but something went wrong.</h1> + <h1>We're sorry, but something went wrong.</h1> </div> - <p>If you are the application owner check the logs for more information.</p> + <p>If you are the application owner check the logs for more information.</p> </div> </body> </html> diff --git a/railties/lib/rails/info_controller.rb b/railties/lib/rails/info_controller.rb index fa5668a5b5..85ea11b4e7 100644 --- a/railties/lib/rails/info_controller.rb +++ b/railties/lib/rails/info_controller.rb @@ -13,10 +13,12 @@ class Rails::InfoController < ActionController::Base # :nodoc: def properties @info = Rails::Info.to_html + @page_title = 'Properties' end def routes @routes_inspector = ActionDispatch::Routing::RoutesInspector.new(_routes.routes) + @page_title = 'Routes' end protected diff --git a/railties/lib/rails/templates/layouts/application.html.erb b/railties/lib/rails/templates/layouts/application.html.erb index 7352d48e7b..50a4755e45 100644 --- a/railties/lib/rails/templates/layouts/application.html.erb +++ b/railties/lib/rails/templates/layouts/application.html.erb @@ -2,7 +2,7 @@ <html lang="en"> <head> <meta charset="utf-8" /> - <title>Routes</title> + <title><%= @page_title %></title> <style> body { background-color: #fff; color: #333; } |