Sha256: fb22fa0f12ac72f5d26a5e3d83d5d6a34c8c3045c2c018f91d839aecaa2e956a
Contents?: true
Size: 703 Bytes
Versions: 1
Compression:
Stored size: 703 Bytes
Contents
require 'rails/generators/active_record' module ActiveRecord module Generators class RemoveGenerator < ActiveRecord::Generators::Base include Rails::Generators::Migration source_root File.expand_path('../templates', __FILE__) desc "Creates a migration file to remove all traces of Merit on the DB" def self.next_migration_number(path) ActiveRecord::Generators::Base.next_migration_number(path) end def copy_migrations_and_model migration_template 'remove_merit_tables.rb', 'db/migrate/remove_merit_tables.rb' migration_template "remove_fields_from_model.rb", "db/migrate/remove_fields_from_#{table_name}" end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
merit-1.7.1 | lib/generators/active_record/remove_generator.rb |