diff options
Diffstat (limited to 'railties/lib/rails/generators/rails/app')
-rw-r--r-- | railties/lib/rails/generators/rails/app/app_generator.rb | 7 | ||||
-rw-r--r-- | railties/lib/rails/generators/rails/app/templates/app/views/layouts/application.html.erb | 9 |
2 files changed, 11 insertions, 5 deletions
diff --git a/railties/lib/rails/generators/rails/app/app_generator.rb b/railties/lib/rails/generators/rails/app/app_generator.rb index df6e98f38d..f7644c3280 100644 --- a/railties/lib/rails/generators/rails/app/app_generator.rb +++ b/railties/lib/rails/generators/rails/app/app_generator.rb @@ -78,7 +78,12 @@ module Rails::Generators end def create_app_files - directory "app" + directory "app/controllers" + directory "app/helpers" + directory "app/models" + inside "app/views/layouts" do + template "application.html.erb" + end end def create_config_files diff --git a/railties/lib/rails/generators/rails/app/templates/app/views/layouts/application.html.erb b/railties/lib/rails/generators/rails/app/templates/app/views/layouts/application.html.erb index 705865ce19..1dd112b4a6 100644 --- a/railties/lib/rails/generators/rails/app/templates/app/views/layouts/application.html.erb +++ b/railties/lib/rails/generators/rails/app/templates/app/views/layouts/application.html.erb @@ -1,13 +1,14 @@ <!DOCTYPE html> <html> <head> - <%= stylesheet_link_tag :all %> - <%= javascript_include_tag :defaults %> - <%= csrf_meta_tag %> + <title><%= app_const_base %></title> + <%%= stylesheet_link_tag :all %> + <%%= javascript_include_tag :defaults %> + <%%= csrf_meta_tag %> </head> <body> -<%= yield %> +<%%= yield %> </body> </html> |