Sha256: 927733fee5ebe34cb3675254da971d4ef35474a04d6da7bbdc5ec89aa5213026

Contents?: true

Size: 411 Bytes

Versions: 43

Compression:

Stored size: 411 Bytes

Contents

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

class VanityGenerator < Rails::Generators::Base
  include Rails::Generators::Migration
  source_root File.expand_path('../templates', __FILE__)

  def self.next_migration_number(path)
    Time.now.utc.strftime("%Y%m%d%H%M%S")
  end

  def create_model_file
    migration_template "vanity_migration.rb", "db/migrate/vanity_migration.rb"
  end
end

Version data entries

43 entries across 43 versions & 4 rubygems

Version Path
fiverr-vanity-1.7.2 lib/generators/vanity_generator.rb
vanity-1.7.1 lib/generators/vanity_generator.rb
vanity-1.7.0 lib/generators/vanity_generator.rb