Skip to content

Instantly share code, notes, and snippets.

@szimek
Created January 30, 2010 17:18
Show Gist options
  • Save szimek/5d0b8f8e510a9abcefaa to your computer and use it in GitHub Desktop.
Save szimek/5d0b8f8e510a9abcefaa to your computer and use it in GitHub Desktop.
require 'rails/generators/migration'
class ActsAsTaggableOnMigrationGenerator < Rails::Generators::Base
include Rails::Generators::Migration
def self.source_root
File.join(File.dirname(__FILE__), 'templates', Rails.configuration.generators.options[:rails][:orm])
end
def create_migration_file
migration_template 'migration.rb', 'db/migrate/acts_as_taggable_on_migration'
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment