Sha256: 6ae4aa5d1f64b30d169342b101fb27f1bc3414cb90d97d06b114252920d64094
Contents?: true
Size: 562 Bytes
Versions: 34
Compression:
Stored size: 562 Bytes
Contents
namespace :db do desc "Creates a new migration file with the specified name" task :new_migration, :name, :options do |t, args| name = args[:name] || ENV['name'] options = args[:options] || ENV['options'] unless name puts "Error: must provide name of migration to generate." puts "For example: rake #{t.name} name=add_field_to_form" abort end if options StandaloneMigrations::Generator.migration name, options.gsub('/', ' ') else StandaloneMigrations::Generator.migration name end end end
Version data entries
34 entries across 34 versions & 4 rubygems