Sha256: cdad17d75b88782eba2f48915c5bfd594b8cf58adb49b376cfcacc63d3732b18
Contents?: true
Size: 702 Bytes
Versions: 11
Compression:
Stored size: 702 Bytes
Contents
# frozen_string_literal: true require 'rails/generators/active_record' module Monarchy class SetupGenerator < Rails::Generators::Base include Rails::Generators::Migration desc 'This generator setups Monarchy' source_root File.expand_path('../../templates', __FILE__) def setup_monarchy template 'config.rb', 'config/initializers/monarchy.rb' migration_template 'migrations/hierarchy.rb', 'db/migrate/monarchy_create_hierarchies.rb' migration_template 'migrations/membership.rb', 'db/migrate/monarchy_create_memberships.rb' end def self.next_migration_number(dirname) ActiveRecord::Generators::Base.next_migration_number(dirname) end end end
Version data entries
11 entries across 11 versions & 1 rubygems