Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

25 lines (20 sloc) 0.57 kB
require 'rake'
namespace :db do
task :prepare do
require 'rubygems'
require 'datamapper'
Dir.glob('lib/*') do |lib|
require lib
end
@config = YAML.load_file(File.join('conf', 'settings.yml'))
DataMapper.setup(:default, @config[:database])
end
desc 'Create the database tables.'
task :migrate => :prepare do
DataMapper.auto_migrate!
end
desc 'Upgrade the database tables.'
task :upgrade => :prepare do
DataMapper.auto_upgrade!
end
end
Jump to Line
Something went wrong with that request. Please try again.