Permalink
Browse files

fixed build calls & names

 - fixed calls in `:cold` & `:testall`
 - added `:build_all` & `:build_all_and_load` aside with `:build_db*` if user wants to call it by hands
  • Loading branch information...
everzet committed Jun 15, 2010
1 parent 7118cad commit 21c7f12952fae5e3c2b471ad3de4cd00a6836dfe
Showing with 37 additions and 7 deletions.
  1. +37 −7 lib/capifony.rb
View
@@ -113,15 +113,15 @@ def load_database_config(data, env)
desc "Need to overwrite the deploy:cold task so it doesn't try to run the migrations."
task :cold do
update
- symfony.orm.build_all_and_load
+ symfony.orm.build_db_and_load
start
end
desc "Deploy the application and run the test suite."
task :testall do
update_code
symlink
- symfony.orm.build_all_and_load
+ symfony.orm.build_db_and_load
symfony.tests.all
end
end
@@ -252,12 +252,22 @@ def load_database_config(data, env)
find_and_execute_task("symfony:#{symfony_orm}:build_classes")
end
- desc "Generate database based on your schema"
+ desc "Generate code & database based on your schema"
+ task :build_all do
+ find_and_execute_task("symfony:#{symfony_orm}:build_all")
+ end
+
+ desc "Generate code & database based on your schema & load fixtures"
+ task :build_all_and_load do
+ find_and_execute_task("symfony:#{symfony_orm}:build_all_and_load")
+ end
+
+ desc "Generate sql & database based on your schema"
task :build_db do
find_and_execute_task("symfony:#{symfony_orm}:build_db")
end
- desc "Generate database based on your schema & load fixtures"
+ desc "Generate sql & database based on your schema & load fixtures"
task :build_db_and_load do
find_and_execute_task("symfony:#{symfony_orm}:build_db_and_load")
end
@@ -305,11 +315,21 @@ def load_database_config(data, env)
end
desc "Generate code & database based on your schema"
+ task :build_all do
+ run "#{php_bin} #{latest_release}/symfony doctrine:build --all --no-confirmation --env=#{symfony_env}"
+ end
+
+ desc "Generate code & database based on your schema & load fixtures"
+ task :build_all_and_load do
+ run "#{php_bin} #{latest_release}/symfony doctrine:build --all --and-load --no-confirmation --env=#{symfony_env}"
+ end
+
+ desc "Generate sql & database based on your schema"
task :build_db do
run "#{php_bin} #{latest_release}/symfony doctrine:build --sql --db --no-confirmation --env=#{symfony_env}"
end
- desc "Generate code & database based on your schema & load fixtures"
+ desc "Generate sql & database based on your schema & load fixtures"
task :build_db_and_load do
run "#{php_bin} #{latest_release}/symfony doctrine:build --sql --db --and-load --no-confirmation --env=#{symfony_env}"
end
@@ -338,12 +358,22 @@ def load_database_config(data, env)
run "php #{latest_release}/symfony propel:build --all-classes --env=#{symfony_env}"
end
- desc "Generate database based on your schema"
+ desc "Generate code & database based on your schema"
+ task :build_all do
+ run "#{php_bin} #{latest_release}/symfony propel:build --sql --db --no-confirmation --env=#{symfony_env}"
+ end
+
+ desc "Generate code & database based on your schema & load fixtures"
+ task :build_all_and_load do
+ run "#{php_bin} #{latest_release}/symfony propel:build --sql --db --and-load --no-confirmation --env=#{symfony_env}"
+ end
+
+ desc "Generate sql & database based on your schema"
task :build_db do
run "#{php_bin} #{latest_release}/symfony propel:build --sql --db --no-confirmation --env=#{symfony_env}"
end
- desc "Generate database based on your schema & load fixtures"
+ desc "Generate sql & database based on your schema & load fixtures"
task :build_db_and_load do
run "#{php_bin} #{latest_release}/symfony propel:build --sql --db --and-load --no-confirmation --env=#{symfony_env}"
end

0 comments on commit 21c7f12

Please sign in to comment.