Sha256: 8ebc2fb8fb98d812f5a4066e4e4b5d2ed4aed64f769cbde1c269a2d14fe29859
Contents?: true
Size: 694 Bytes
Versions: 15
Compression:
Stored size: 694 Bytes
Contents
module Freyr class CLI < Thor desc 'update_pid [SERVICE=dirname]', 'Update pid from proc_match (good to use if service already launched)' def update_pid(name=nil) services = get_from_name(name) if s = services.first if pid = s.command.update_pid say "Updated pid for "<< set_color(s.name,:blue) << ' to ' << set_color(pid,:red) elsif s.proc_match say "Couldn't find pid for process matcher #{s.proc_match.inspect}", :red else say "Service #{s.name} doesn't have a value for proc_match set.", :red end else say "Couldn't find service with name #{name}.", :red end end end end
Version data entries
15 entries across 15 versions & 1 rubygems