Sha256: 8857596442f467cca5893187d29cbfa7addf3a8465503b482f0f3e7bbb1598f8

Contents?: true

Size: 539 Bytes

Versions: 11

Compression:

Stored size: 539 Bytes

Contents

require 'rails/generators'
require 'rails/generators/migration'
require 'rails/generators/active_record/migration'

module PaperTrail
  class InstallGenerator < Rails::Generators::Base
    include Rails::Generators::Migration
    extend ActiveRecord::Generators::Migration

    source_root File.expand_path('../templates', __FILE__)

    desc 'Generates (but does not run) a migration to add a versions table.'

    def create_migration_file
      migration_template 'create_versions.rb', 'db/migrate/create_versions.rb'
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
paper_trail-2.2.6 lib/generators/paper_trail/install_generator.rb
paper_trail-2.2.5 lib/generators/paper_trail/install_generator.rb
paper_trail-2.2.4 lib/generators/paper_trail/install_generator.rb
paper_trail-2.2.3 lib/generators/paper_trail/install_generator.rb
paper_trail-2.2.2 lib/generators/paper_trail/install_generator.rb
paper_trail-2.2.1 lib/generators/paper_trail/install_generator.rb
paper_trail-2.2.0 lib/generators/paper_trail/install_generator.rb
paper_trail-2.1.1 lib/generators/paper_trail/install_generator.rb
paper_trail-2.1.0 lib/generators/paper_trail/install_generator.rb
paper_trail-2.0.2 lib/generators/paper_trail/install_generator.rb
paper_trail-2.0.1 lib/generators/paper_trail/install_generator.rb