Sha256: 5ba3fd70c4ef3f5d05622c773f47846fb6bbd880214ec720c42babd8fe80ff93

Contents?: true

Size: 782 Bytes

Versions: 6

Compression:

Stored size: 782 Bytes

Contents

# encoding: UTF-8

namespace :iqvoc_inflectionals do
  namespace :db do

    desc "Migrate the database through scripts in db/migrate and update db/schema.rb by invoking db:schema:dump. Target specific version with VERSION=x. Turn off output with VERBOSE=false."
    task :migrate => :environment do
      ActiveRecord::Migration.verbose = ENV["VERBOSE"] ? ENV["VERBOSE"] == "true" : true
      ActiveRecord::Migrator.migrate(Iqvoc::Inflectionals::Engine.find_root_with_flag("db").join('db/migrate'), ENV["VERSION"] ? ENV["VERSION"].to_i : nil)
      Rake::Task["db:schema:dump"].invoke if ActiveRecord::Base.schema_format == :ruby
    end

    desc "Load seeds (task is idempotent)"
    task :seed => :environment do
      Iqvoc::Inflectionals::Engine.load_seed
    end

  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
iqvoc_inflectionals-2.0.1 lib/engine_tasks/db.rake
iqvoc_inflectionals-2.0.0 lib/engine_tasks/db.rake
iqvoc_inflectionals-1.1.3 lib/engine_tasks/db.rake
iqvoc_inflectionals-1.1.1 lib/engine_tasks/db.rake
iqvoc_inflectionals-1.1.0 lib/engine_tasks/db.rake
iqvoc_inflectionals-1.0.1 lib/engine_tasks/db.rake