Sha256: 7434075a2041cacf507d0b16d945151c01a9cb2f78e977b5802d15810cd4ba45
Contents?: true
Size: 586 Bytes
Versions: 9
Compression:
Stored size: 586 Bytes
Contents
# frozen_string_literal: true require 'rails/generators' module Blacklight class DocumentGenerator < Rails::Generators::Base include Rails::Generators::Migration source_root File.expand_path('../templates', __FILE__) argument :model_name, :type => :string , :default => "solr_document" desc <<-EOS This generator makes the following changes to your application: 1. Creates a blacklight document in your /app/models directory EOS def create_solr_document template "solr_document.rb", "app/models/#{model_name}.rb" end end end
Version data entries
9 entries across 9 versions & 1 rubygems