Updated CLI and Config to default to not writing a pidfile unless daemonized.

This commit is contained in:
Thomas Drake-Brockman
2015-04-02 03:14:08 +08:00
parent 48db3ef245
commit 4b28f3dd80
3 changed files with 33 additions and 2 deletions

View File

@@ -50,6 +50,7 @@ module Crono
end
def write_pid
return unless config.pidfile
pidfile = File.expand_path(config.pidfile)
File.write(pidfile, ::Process.pid)
end