Run rake tasks from ruby script

Updated . Posted . Visible to the public. Repeats.
require 'rake'

rake = Rake.application
rake.init
# you can import addition *.rake files
# app.add_import 'some/other/file.rake'
rake.load_rakefile
rake['db:test:prepare'].invoke()
konjoot
Last edit
konjoot
Keywords
Rake
Posted by konjoot to wiki (2014-01-11 12:36)