# File lib/god/cli/run.rb, line 36 def default_run # make sure we have STDIN/STDOUT redirected immediately setup_logging # start attached pid watcher if necessary if @options[:attach] self.attach end if @options[:port] God.port = @options[:port] end if @options[:events] God::EventHandler.load end # set log level, defaults to WARN if @options[:log_level] God.log_level = @options[:log_level] else God.log_level = @options[:daemonize] ? :warn : :info end if @options[:config] unless File.exist?(@options[:config]) abort "File not found: #{@options[:config]}" end # start the event handler God::EventHandler.start if God::EventHandler.loaded? load_config @options[:config] end setup_logging end