Sha256: 00aba330d2e77cfd3bf23ea70860d8b1a5570361e8c961e6b3166f61331bbdcd
Contents?: true
Size: 862 Bytes
Versions: 4
Compression:
Stored size: 862 Bytes
Contents
require 'rails/generaTors/migration' module TkhMailingList module Generators class CreateOrUpdateMigrationsGenerator < ::Rails::Generators::Base include Rails::Generators::Migration source_root File.expand_path('../templates', __FILE__) desc "add the migrations and locale files" def self.next_migration_number(path) unless @prev_migration_nr @prev_migration_nr = Time.now.utc.strftime("%Y%m%d%H%M%S").to_i else @prev_migration_nr += 1 end @prev_migration_nr.to_s end def copy_migrations puts 'creating user migration' migration_template "add_teacher_status_to_users.rb", "db/migrate/add_teacher_status_to_users.rb" migration_template "add_profile_fields_to_users.rb", "db/migrate/add_profile_fields_to_users.rb" end end end end
Version data entries
4 entries across 4 versions & 1 rubygems