Sha256: 7eecabde1c2bb853327c2d8e93537c84e480582a0cb7050926aa6754523d85ea
Contents?: true
Size: 555 Bytes
Versions: 13
Compression:
Stored size: 555 Bytes
Contents
require "detour" require "rails/generators" require "rails/generators/active_record" class DetourGenerator < Rails::Generators::Base include Rails::Generators::Migration extend ActiveRecord::Generators::Migration source_root File.expand_path("../templates", __FILE__) desc "Creates migration for Detour" def create_migration_file migration_template "migration.rb", "db/migrate/setup_detour.rb" end desc "Sets up an initializer for Detour" def create_initializer copy_file "detour.rb", "config/initializers/detour.rb" end end
Version data entries
13 entries across 13 versions & 1 rubygems