Class: AuthorizedRailsScaffolds::InstallTemplatesGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- AuthorizedRailsScaffolds::InstallTemplatesGenerator
- Defined in:
- lib/generators/authorized_rails_scaffolds/install_templates/install_templates_generator.rb
Instance Method Summary collapse
Instance Method Details
#copy_rails_templates ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 |
# File 'lib/generators/authorized_rails_scaffolds/install_templates/install_templates_generator.rb', line 4 def copy_rails_templates # Controller Templates copy_rails_scaffold_controller 'controller.rb' # View Templates (erb) copy_erb_scaffold_template '_form.html.erb' copy_erb_scaffold_template 'edit.html.erb' copy_erb_scaffold_template 'index.html.erb' copy_erb_scaffold_template 'new.html.erb' copy_erb_scaffold_template 'show.html.erb' end |
#create_spec_templates ⇒ Object
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 |
# File 'lib/generators/authorized_rails_scaffolds/install_templates/install_templates_generator.rb', line 16 def create_spec_templates # Controller Spec Templates copy_rspec_scaffold_template 'controller_spec.rb' # Model Spec Templates copy_rspec_model_template 'model_spec.rb' # Helper Spec Template copy_rails_helper_controller 'helper.rb' # Request Spec Templates copy_rspec_integration_template 'request_spec.rb' # Routing Spec Templates copy_rspec_scaffold_template 'routing_spec.rb' # View Spec Templates copy_rspec_scaffold_template 'edit_spec.rb' copy_rspec_scaffold_template 'index_spec.rb' copy_rspec_scaffold_template 'new_spec.rb' copy_rspec_scaffold_template 'show_spec.rb' end |