Sha256: abf2a814191174931e018b4e6e75437530428a9f7e1449c8ede874fa1478458a

Contents?: true

Size: 425 Bytes

Versions: 58

Compression:

Stored size: 425 Bytes

Contents

module Para
  class ImporterGenerator < Rails::Generators::NamedBase
    source_root File.expand_path('../templates', __FILE__)

    desc 'Para importer generator'

    def copy_resource_importer
      template(
        "base_importer.rb",
        "app/importers/#{ plural_file_name }_importer.rb"
      )
    end

    private

    def model_importer_name
      [class_name.to_s.pluralize, 'Importer'].join
    end
  end
end

Version data entries

58 entries across 58 versions & 1 rubygems

Version Path
para-0.8.12 lib/generators/para/importer/importer_generator.rb
para-0.8.11 lib/generators/para/importer/importer_generator.rb
para-0.8.10 lib/generators/para/importer/importer_generator.rb
para-0.8.9 lib/generators/para/importer/importer_generator.rb
para-0.8.8 lib/generators/para/importer/importer_generator.rb
para-0.8.7 lib/generators/para/importer/importer_generator.rb
para-0.8.5 lib/generators/para/importer/importer_generator.rb
para-0.8.3.3 lib/generators/para/importer/importer_generator.rb
para-0.8.3.2 lib/generators/para/importer/importer_generator.rb
para-0.8.3.1 lib/generators/para/importer/importer_generator.rb
para-0.8.3 lib/generators/para/importer/importer_generator.rb
para-0.8.2.3 lib/generators/para/importer/importer_generator.rb
para-0.8.2.2 lib/generators/para/importer/importer_generator.rb
para-0.8.2.1 lib/generators/para/importer/importer_generator.rb
para-0.8.2 lib/generators/para/importer/importer_generator.rb
para-0.8.1 lib/generators/para/importer/importer_generator.rb
para-0.8.0 lib/generators/para/importer/importer_generator.rb
para-0.7.4.p1 lib/generators/para/importer/importer_generator.rb
para-0.7.4 lib/generators/para/importer/importer_generator.rb
para-0.7.3.p6 lib/generators/para/importer/importer_generator.rb