Class: AuxiliaryRails::CommandGenerator
- Inherits:
-
Rails::Generators::NamedBase
- Object
- Rails::Generators::NamedBase
- AuxiliaryRails::CommandGenerator
- Defined in:
- lib/generators/auxiliary_rails/command_generator.rb
Instance Method Summary collapse
Instance Method Details
#create_command_file ⇒ Object
14 15 16 17 18 |
# File 'lib/generators/auxiliary_rails/command_generator.rb', line 14 def create_command_file FileUtils.mkdir_p(command_file_path) template 'command_template.rb', "#{command_file_path}/#{command_file_name}.rb" end |
#create_command_spec_file ⇒ Object
20 21 22 23 24 |
# File 'lib/generators/auxiliary_rails/command_generator.rb', line 20 def create_command_spec_file FileUtils.mkdir_p(command_spec_path) template 'command_spec_template.rb', "#{command_spec_path}/#{command_file_name}_spec.rb" end |