fix a dumb thing and another thing
This commit is contained in:
parent
2654061350
commit
d0901933c1
|
@ -22,6 +22,7 @@ module Guard
|
||||||
def stop
|
def stop
|
||||||
if File.file?(pid_file)
|
if File.file?(pid_file)
|
||||||
system %{kill -KILL #{File.read(pid_file).strip}}
|
system %{kill -KILL #{File.read(pid_file).strip}}
|
||||||
|
sleep sleep_time
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -75,7 +76,7 @@ module Guard
|
||||||
|
|
||||||
def unmanaged_pid
|
def unmanaged_pid
|
||||||
pid_command = "lsof -n -i TCP:#{options[:port]}"
|
pid_command = "lsof -n -i TCP:#{options[:port]}"
|
||||||
%x{pid_command}.each_line { |line|
|
%x{#{pid_command}}.each_line { |line|
|
||||||
if line["*:#{options[:port]} "]
|
if line["*:#{options[:port]} "]
|
||||||
return line.split("\s")[1]
|
return line.split("\s")[1]
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue