Skip to content
This repository
Browse code

We changed name to scaffold

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6768 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
  • Loading branch information...
commit 249d55e684ba7808807fe270cef75955e5bc4e69 1 parent 18326e3
David Heinemeier Hansson dhh authored
2  railties/lib/rails_generator/generators/components/resource/USAGE
@@ -21,7 +21,7 @@ Description:
21 21 your config/routes.rb file, hooking up the rules that'll point URLs to
22 22 this new resource.
23 23
24   - Unlike the scaffold_resource generator, the resource generator does not
  24 + Unlike the scaffold generator, the resource generator does not
25 25 create views or add any methods to the generated controller.
26 26
27 27 Examples:
6 railties/lib/rails_generator/generators/components/scaffold/USAGE
@@ -9,14 +9,14 @@ Description:
9 9
10 10 The generator takes the name of the model as its first argument. This
11 11 model name is then pluralized to get the controller name. So
12   - "scaffold_resource post" will generate a Post model and a
  12 + "scaffold post" will generate a Post model and a
13 13 PostsController and will be intended for URLs like /posts and
14 14 /posts/45.
15 15
16 16 As additional parameters, the generator will take attribute pairs
17 17 described by name and type. These attributes will be used to
18 18 prepopulate the migration to create the table for the model and to give
19   - you a set of templates for the view. For example, "scaffold_resource
  19 + you a set of templates for the view. For example, "scaffold
20 20 post title:string created_on:date body:text published:boolean" will
21 21 give you a model with those four attributes, forms to create and edit
22 22 those models from, and an index that'll list them all.
@@ -27,7 +27,7 @@ Description:
27 27
28 28 The generator also adds a declaration to your config/routes.rb file
29 29 to hook up the rules that'll point URLs to this new resource. If you
30   - create a resource like "scaffold_resource post", it will add
  30 + create a resource like "scaffold post", it will add
31 31 "map.resources :posts" (notice the plural form) in the routes file,
32 32 making your new resource accessible from /posts.
33 33
2  railties/lib/rails_generator/scripts/destroy.rb
@@ -18,7 +18,7 @@ def usage_message
18 18 This script will destroy all files created by the corresponding
19 19 script/generate command. For instance, script/destroy migration CreatePost
20 20 will delete the appropriate ###_create_post.rb file in db/migrate, while
21   -script/destroy scaffold_resource Post will delete the posts controller and
  21 +script/destroy scaffold Post will delete the posts controller and
22 22 views, post model and migration, all associated tests, and the map.resources
23 23 :posts line in config/routes.rb.
24 24

0 comments on commit 249d55e

Please sign in to comment.
Something went wrong with that request. Please try again.