#!/usr/bin/env ruby require 'sys_watchdog' case ARGV[0] when %w(setup start stop uninstall) Setup.new.send ARGV[0].to_sym when 'test' sw = SysWatchdog.new log_file: STDOUT sw.run once: true when 'once' SysWatchdog.new.run once: true when nil SysWatchdog.new.run end