Sha256: 000a777ea99188cbe484917a2fdb5d451a731086d8fca17b9c9a79897d03b12a
Contents?: true
Size: 643 Bytes
Versions: 1
Compression:
Stored size: 643 Bytes
Contents
require 'generators/data_migrate' require 'rails/generators' require 'rails/generators/migration' module DataMigrate module Generators class InstallGenerator < Rails::Generators::Base include Rails::Generators::Migration def create_migration_file migration_template "install_migration.rb", "db/migrate/create_data_migrations.rb" end protected def self.next_migration_number(dirname) if ActiveRecord::Base.timestamped_migrations Time.new.utc.strftime("%Y%m%d%H%M%S") else "%.3d" % (current_migration_number(dirname) + 1) end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
data_migrate-1.0.0 | lib/generators/data_migrate/install/install_generator.rb |