Sha256: feb36fe5081ed2d3847736b216c49d7b7ba4425087b456dd15ac493003b046ae
Contents?: true
Size: 618 Bytes
Versions: 13
Compression:
Stored size: 618 Bytes
Contents
require "rails/generators/active_record" module FieldTest module Generators class InstallGenerator < Rails::Generators::Base include ActiveRecord::Generators::Migration source_root File.join(__dir__, "templates") def copy_migration migration_template "memberships.rb", "db/migrate/create_field_test_memberships.rb", migration_version: migration_version end def copy_config template "config.yml", "config/field_test.yml" end def migration_version "[#{ActiveRecord::VERSION::MAJOR}.#{ActiveRecord::VERSION::MINOR}]" end end end end
Version data entries
13 entries across 13 versions & 1 rubygems