guard-spork 0.1.0 → 0.1.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -10,6 +10,7 @@ module Guard
10
10
  def initialize(watchers = [], options = {})
11
11
  super
12
12
  @runner = Runner.new(options)
13
+
13
14
  end
14
15
 
15
16
  def start
@@ -20,7 +20,7 @@ module Guard
20
20
  end
21
21
 
22
22
  def kill_sporks
23
- system("kill $(ps aux | awk '/spork/&&!/awk/{print $2;}') >/dev/null 2>&1")
23
+ spork_pids.each { |pid| Process.kill("KILL", pid) }
24
24
  end
25
25
 
26
26
  private
@@ -61,6 +61,10 @@ module Guard
61
61
  Notifier.notify "#{sporked_gems} NOT #{action}ed", :title => "Spork", :image => :failed
62
62
  end
63
63
 
64
+ def spork_pids
65
+ `ps aux | awk '/spork/&&!/awk/{print $2;}'`.split("\n").map { |pid| pid.to_i }
66
+ end
67
+
64
68
  def sporked_gems
65
69
  gems = []
66
70
  gems << "RSpec" if rspec?
@@ -1,5 +1,5 @@
1
1
  module Guard
2
2
  module SporkVersion
3
- VERSION = "0.1.0"
3
+ VERSION = "0.1.3"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: guard-spork
3
3
  version: !ruby/object:Gem::Version
4
- hash: 27
4
+ hash: 29
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 0
10
- version: 0.1.0
9
+ - 3
10
+ version: 0.1.3
11
11
  platform: ruby
12
12
  authors:
13
13
  - Thibaud Guillaume-Gentil
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-11-11 00:00:00 +01:00
18
+ date: 2010-11-18 00:00:00 +01:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
@@ -58,12 +58,12 @@ dependencies:
58
58
  requirements:
59
59
  - - ~>
60
60
  - !ruby/object:Gem::Version
61
- hash: 17
61
+ hash: 25
62
62
  segments:
63
63
  - 1
64
64
  - 0
65
- - 3
66
- version: 1.0.3
65
+ - 7
66
+ version: 1.0.7
67
67
  type: :development
68
68
  version_requirements: *id003
69
69
  - !ruby/object:Gem::Dependency
@@ -81,6 +81,22 @@ dependencies:
81
81
  version: "2.1"
82
82
  type: :development
83
83
  version_requirements: *id004
84
+ - !ruby/object:Gem::Dependency
85
+ name: guard-rspec
86
+ prerelease: false
87
+ requirement: &id005 !ruby/object:Gem::Requirement
88
+ none: false
89
+ requirements:
90
+ - - ~>
91
+ - !ruby/object:Gem::Version
92
+ hash: 11
93
+ segments:
94
+ - 0
95
+ - 1
96
+ - 8
97
+ version: 0.1.8
98
+ type: :development
99
+ version_requirements: *id005
84
100
  description: Guard::Spork automatically manage Spork DRb servers
85
101
  email:
86
102
  - thibaud@thibaud.me