six-updater 0.17.6 → 0.17.7
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +3 -3
- data/lib/six/updater.rb +22 -17
- metadata +3 -3
data/Rakefile
CHANGED
@@ -13,7 +13,7 @@ require 'rake/testtask'
|
|
13
13
|
spec = Gem::Specification.new do |s|
|
14
14
|
s.platform = "x86-mingw32"
|
15
15
|
s.name = 'six-updater'
|
16
|
-
s.version = '0.17.
|
16
|
+
s.version = '0.17.7'
|
17
17
|
s.has_rdoc = true
|
18
18
|
s.extra_rdoc_files = ['README', 'LICENSE']
|
19
19
|
s.summary = 'Your summary here'
|
@@ -35,7 +35,7 @@ end
|
|
35
35
|
spec3 = Gem::Specification.new do |s|
|
36
36
|
s.platform = "x86-mswin32"
|
37
37
|
s.name = 'six-updater'
|
38
|
-
s.version = '0.17.
|
38
|
+
s.version = '0.17.7'
|
39
39
|
s.has_rdoc = true
|
40
40
|
s.extra_rdoc_files = ['README', 'LICENSE']
|
41
41
|
s.summary = 'Your summary here'
|
@@ -56,7 +56,7 @@ end
|
|
56
56
|
|
57
57
|
spec2 = Gem::Specification.new do |s|
|
58
58
|
s.name = 'six-updater'
|
59
|
-
s.version = '0.17.
|
59
|
+
s.version = '0.17.7'
|
60
60
|
s.has_rdoc = true
|
61
61
|
s.extra_rdoc_files = ['README', 'LICENSE']
|
62
62
|
s.summary = 'Your summary here'
|
data/lib/six/updater.rb
CHANGED
@@ -38,7 +38,7 @@ end
|
|
38
38
|
module Six
|
39
39
|
# TODO: Evaluate if this module should be a class instead?
|
40
40
|
module Updater
|
41
|
-
VERSION = '0.17.
|
41
|
+
VERSION = '0.17.7'
|
42
42
|
COMPONENT = 'six-updater'
|
43
43
|
LOG_LIMIT = 9999
|
44
44
|
FOLDER = /(.*)\/(.*)/
|
@@ -352,25 +352,30 @@ module Six
|
|
352
352
|
# TODO: Filter for process's folder.
|
353
353
|
|
354
354
|
pids = []
|
355
|
-
|
356
|
-
|
357
|
-
|
358
|
-
|
359
|
-
|
360
|
-
|
361
|
-
|
362
|
-
pid
|
363
|
-
|
355
|
+
begin
|
356
|
+
case RUBY_PLATFORM
|
357
|
+
when /-mingw32$/, /-mswin32$/
|
358
|
+
out = %x[tasklist]
|
359
|
+
out.split("\n").each do |line|
|
360
|
+
if line =~ /\A#{name}[\t| ]*([0-9]*)/
|
361
|
+
pid = $1
|
362
|
+
if pid.size > 0
|
363
|
+
pid = pid.to_i
|
364
|
+
pids << pid
|
365
|
+
end
|
364
366
|
end
|
365
367
|
end
|
366
|
-
|
367
|
-
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
368
|
+
else
|
369
|
+
%x[ps -A | grep #{name}].split("\n").each do |line|
|
370
|
+
unless line[/grep/]
|
371
|
+
line[/^\s*([0-9]*)/]
|
372
|
+
pids << $1
|
373
|
+
end
|
372
374
|
end
|
373
|
-
|
375
|
+
end
|
376
|
+
rescue
|
377
|
+
log.warn "Failed checking tasklist for #{name}"
|
378
|
+
log.debug "#{$!}"
|
374
379
|
end
|
375
380
|
pids
|
376
381
|
end
|
metadata
CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
|
|
5
5
|
segments:
|
6
6
|
- 0
|
7
7
|
- 17
|
8
|
-
-
|
9
|
-
version: 0.17.
|
8
|
+
- 7
|
9
|
+
version: 0.17.7
|
10
10
|
platform: ruby
|
11
11
|
authors:
|
12
12
|
- Sickboy
|
@@ -14,7 +14,7 @@ autorequire:
|
|
14
14
|
bindir: bin
|
15
15
|
cert_chain: []
|
16
16
|
|
17
|
-
date: 2010-04-
|
17
|
+
date: 2010-04-23 00:00:00 +02:00
|
18
18
|
default_executable:
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|