From 7a8ed3bbbf44b273622be0e324a616065f5656a8 Mon Sep 17 00:00:00 2001 From: David Heinemeier Hansson Date: Fri, 28 Apr 2006 00:00:50 +0000 Subject: Added pid file usage to script/process/spawner and script/process/reaper along with a directive in default config/lighttpd.conf file to record the pid. They will all save their pid file in tmp/pids [DHH] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4294 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- railties/lib/tasks/tmp.rake | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'railties/lib/tasks') diff --git a/railties/lib/tasks/tmp.rake b/railties/lib/tasks/tmp.rake index 6ba5b11450..b191039d63 100644 --- a/railties/lib/tasks/tmp.rake +++ b/railties/lib/tasks/tmp.rake @@ -4,7 +4,7 @@ namespace :tmp do desc "Creates tmp directories for sessions, cache, and sockets" task :create do - FileUtils.mkdir_p(%w( tmp/sessions tmp/cache tmp/sockets )) + FileUtils.mkdir_p(%w( tmp/sessions tmp/cache tmp/sockets tmp/pids )) end namespace :sessions do @@ -27,4 +27,11 @@ namespace :tmp do FileUtils.rm(Dir['tmp/sockets/[^.]*']) end end + + namespace :pids do + desc "Clears all files in tmp/pids" + task :clear do + FileUtils.rm(Dir['tmp/pids/[^.]*']) + end + end end \ No newline at end of file -- cgit v1.2.3