Permalink
Browse files

Add a setup task that does all the legwork of getting Tolk running in…

… your app
  • Loading branch information...
1 parent 18fb33c commit 77d0ed33779aba34b92ccf3af78311539aff924c @dhh dhh committed Jun 7, 2010
Showing with 9 additions and 0 deletions.
  1. +9 −0 lib/tasks/tolk_tasks.rake
@@ -1,4 +1,13 @@
namespace :tolk do
+ desc "Add database tables, copy over the assets, and import existing translations"
+ task :setup => :environment do
+ Rake::Task['tolk:import_assets'].invoke
+ system("rails generate tolk_migration")
+ Rake::Task['db:migrate'].invoke
+ Rake::Task['tolk:sync'].invoke
+ Rake::Task['tolk:import'].invoke
+ end
+
desc "Sync Tolk with the default locale's yml file"
task :sync => :environment do
Tolk::Locale.sync!

0 comments on commit 77d0ed3

Please sign in to comment.