From 0774f22941f6846acd79a07d43cd417cd09a1998 Mon Sep 17 00:00:00 2001 From: Jason Noble Date: Sun, 13 Nov 2011 03:13:58 -0700 Subject: Convert tables to table format --- railties/guides/source/getting_started.textile | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) (limited to 'railties') diff --git a/railties/guides/source/getting_started.textile b/railties/guides/source/getting_started.textile index d0ba07a82d..f387dddce8 100644 --- a/railties/guides/source/getting_started.textile +++ b/railties/guides/source/getting_started.textile @@ -1135,9 +1135,11 @@ $ rails generate model Comment commenter:string body:text post:references This command will generate four files: -* +app/models/comment.rb+ - The model. -* +db/migrate/20100207235629_create_comments.rb+ - The migration. -* +test/unit/comment_test.rb+ and +test/fixtures/comments.yml+ - The test harness. +|_.File |_.Purpose| +|db/migrate/20100207235629_create_comments.rb | Migration to create the comments table in your database (your name will include a different timestamp) | +| app/models/comment.rb | The Comment model | +| test/unit/comment_test.rb | Unit testing harness for the comments model | +| test/fixtures/comments.yml | Sample comments for use in testing | First, take a look at +comment.rb+: @@ -1258,13 +1260,14 @@ $ rails generate controller Comments This creates six files and one empty directory: -* +app/controllers/comments_controller.rb+ - The controller. -* +app/helpers/comments_helper.rb+ - A view helper file. -* +test/functional/comments_controller_test.rb+ - The functional tests for the controller. -* +test/unit/helpers/comments_helper_test.rb+ - The unit tests for the helper. -* +app/views/comments/+ - Views of the controller are stored here. -* +app/assets/stylesheets/comment.css.scss+ - Cascading style sheet for the controller. -* +app/assets/javascripts/comment.js.coffee+ - CoffeeScript for the controller. +|_.File/Directory |_.Purpose | +| app/controllers/comments_controller.rb | The Comments controller | +| app/views/comments/ | Views of the controller are stored here | +| test/functional/comments_controller_test.rb | The functional tests for the controller | +| app/helpers/comments_helper.rb | A view helper file | +| test/unit/helpers/comments_helper_test.rb | The unit tests for the helper | +| app/assets/javascripts/comment.js.coffee | CoffeeScript for the controller | +| app/assets/stylesheets/comment.css.scss | Cascading style sheet for the controller | Like with any blog, our readers will create their comments directly after reading the post, and once they have added their comment, will be sent back to -- cgit v1.2.3