Created
April 24, 2009 00:03
-
-
Save kt103099/100851 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace :db do | |
desc "Load seed fixtures (from db/fixtures) into the current environment's database." | |
task :seed => :environment do | |
require 'active_record/fixtures' | |
Dir.glob(RAILS_ROOT + '/db/fixtures/*.yml').each do |file| | |
Fixtures.create_fixtures('db/fixtures', File.basename(file, '.*')) | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment