Sha256: f49ac2d265891fc52ae810b02e38d9df8ebb5ce0b75cab6bec230aac49396a0f

Contents?: true

Size: 1.01 KB

Versions: 2

Compression:

Stored size: 1.01 KB

Contents

How to create a Generator (aka Application Generator)
======================================

1. DONE - Run the generator: script/generate application_generator myapp
2. Using the generated test class, assert what directories, files, classes etc should
   be generated.
3. Add these files into the app_genearators/myapp/templates folder. Your files can use
   ERb (that is, <%= ... %>).
4. Specify who the files in /templates are copied/templated at generation time within app_genearators/myapp/myapp_generators.rb's #manifest method.
   Use m.file for files to copy over.
   Use m.template for files containing ERb. Create attr_reader accessors for any variables your
   templates need access to.
5. Run unit tests.
6. Update your Manifest.txt with the new files (rake manifest:refresh)
7. Build and install your RubyGem locally. Run: rake install_gem
8. Go to a directory where you can create new test apps.
9. Run 'myapp [path]' and your application skeleton will be created.

See this message again using the -h/--help option.

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
newgem-0.14.1 rubygems_generators/application_generator/templates/readme
newgem-0.14.2 rubygems_generators/application_generator/templates/readme