Class: RailsExporter::ExporterGenerator

Inherits:
Rails::Generators::NamedBase
  • Object
show all
Defined in:
lib/generators/rails_exporter/exporter_generator.rb

Instance Method Summary collapse

Instance Method Details

#generate_exporterObject



7
8
9
10
# File 'lib/generators/rails_exporter/exporter_generator.rb', line 7

def generate_exporter
  @exporter_name = file_name.classify
  template "generic_exporter.erb", File.join('app/exporters', "#{file_name.underscore}_exporter.rb")
end