From 03c32c6d806136b99d54b4e1d3b662a5acf48d3f Mon Sep 17 00:00:00 2001 From: Mohnish Thallavajhula Date: Mon, 4 May 2015 22:32:07 -0700 Subject: Use the built-in rake tasks Use the `log:clear` and `tmp:clear` rake tasks in the setup file template --- railties/lib/rails/generators/rails/app/templates/bin/setup | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'railties') diff --git a/railties/lib/rails/generators/rails/app/templates/bin/setup b/railties/lib/rails/generators/rails/app/templates/bin/setup index eee810be30..0556cbd355 100644 --- a/railties/lib/rails/generators/rails/app/templates/bin/setup +++ b/railties/lib/rails/generators/rails/app/templates/bin/setup @@ -22,8 +22,8 @@ chdir APP_ROOT do system 'ruby bin/rake db:setup' puts "\n== Removing old logs and tempfiles ==" - rm_f Dir.glob('log/*') - rm_rf 'tmp/cache' + system 'ruby bin/rake log:clear' + system 'ruby bin/rake tmp:clear' puts "\n== Restarting application server ==" touch 'tmp/restart.txt' -- cgit v1.2.3