Guest User

Untitled

a guest
Mar 3rd, 2017
137
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. require 'rails/generators/active_record/migration/migration_generator'
  2.  
  3. class LogMigrationGenerator < ActiveRecord::Generators::MigrationGenerator
  4.   include Rails::Generators::Actions
  5.   source_root File.join(File.dirname(ActiveRecord::Generators::MigrationGenerator.instance_method(:create_migration_file).source_location.first), "templates")
  6.  
  7.   def create_migration_file
  8.     set_local_assigns!
  9.     validate_file_name!
  10.     migration_template @migration_template, "db_log/migrate/#{file_name}.rb"
  11.   end
  12. end
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×