Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

'rails generate plugin' --with-generator option has changed to --gene…

…rator. Updated the output that is seen after executing 'rails generate plugin yaffle --generator'
  • Loading branch information...
commit 89eef55fb338ecf84014b9641d4bc0ca1cbe7e05 1 parent 0c6ac67
@andrewferk andrewferk authored
Showing with 20 additions and 17 deletions.
  1. +20 −17 railties/guides/source/plugins.textile
View
37 railties/guides/source/plugins.textile
@@ -52,44 +52,47 @@ NOTE: The aforementioned instructions will work for sqlite3. For more detailed
h4. Generate the Plugin Skeleton
-Rails ships with a plugin generator which creates a basic plugin skeleton. Pass the plugin name, either 'CamelCased' or 'under_scored', as an argument. Pass +--with-generator+ to add an example generator also.
+Rails ships with a plugin generator which creates a basic plugin skeleton. Pass the plugin name, either 'CamelCased' or 'under_scored', as an argument. Pass +--generator+ to add an example generator also.
This creates a plugin in +vendor/plugins+ including an +init.rb+ and +README+ as well as standard +lib+, +task+, and +test+ directories.
Examples:
<shell>
rails generate plugin yaffle
-rails generate plugin yaffle --with-generator
+rails generate plugin yaffle --generator
</shell>
To get more detailed help on the plugin generator, type +rails generate plugin+.
-Later on this guide will describe how to work with generators, so go ahead and generate your plugin with the +--with-generator+ option now:
+Later on this guide will describe how to work with generators, so go ahead and generate your plugin with the +--generator+ option now:
<shell>
-rails generate plugin yaffle --with-generator
+rails generate plugin yaffle --generator
</shell>
You should see the following output:
<shell>
-create vendor/plugins/yaffle/lib
-create vendor/plugins/yaffle/tasks
-create vendor/plugins/yaffle/test
-create vendor/plugins/yaffle/README
-create vendor/plugins/yaffle/MIT-LICENSE
-create vendor/plugins/yaffle/Rakefile
+create vendor/plugins/yaffle
create vendor/plugins/yaffle/init.rb
create vendor/plugins/yaffle/install.rb
+create vendor/plugins/yaffle/MIT-LICENSE
+create vendor/plugins/yaffle/Rakefile
+create vendor/plugins/yaffle/README
create vendor/plugins/yaffle/uninstall.rb
+create vendor/plugins/yaffle/lib
create vendor/plugins/yaffle/lib/yaffle.rb
-create vendor/plugins/yaffle/tasks/yaffle_tasks.rake
-create vendor/plugins/yaffle/test/core_ext_test.rb
-create vendor/plugins/yaffle/generators
-create vendor/plugins/yaffle/generators/yaffle
-create vendor/plugins/yaffle/generators/yaffle/templates
-create vendor/plugins/yaffle/generators/yaffle/yaffle_generator.rb
-create vendor/plugins/yaffle/generators/yaffle/USAGE
+invoke generator
+inside vendor/plugins/yaffle
+create lib/generators
+create lib/generators/yaffle_generator.rb
+create lib/generators/USAGE
+create lib/generators/templates
+invoke test_unit
+inside vendor/plugins/yaffle
+create test
+create test/yaffle_test.rb
+create test/test_helper.rb
</shell>
h4. Organize Your Files
Please sign in to comment.
Something went wrong with that request. Please try again.