namespace :db do desc 'Imports test data from MusicBrainz database' task :import, [:name, :dry_run] => :environment do |t, argv| if argv[:dry_run].nil? or argv[:dry_run] == "true" argv[:dry_run] = true else argv[:dry_run] = false end unless argv[:name].nil? ImportController.importArtist(argv[:name], argv[:dry_run]) end end end