runnable 0.3.0 → 0.3.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -11,6 +11,7 @@ inherit from class Runnable.
11
11
 
12
12
  That gives you the basics to control the execution of ```ls``` command.
13
13
  You can overwrite the name of the command by using the ```executes``` macro:
14
+
14
15
  class MyLs
15
16
  include Runnable
16
17
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.3.0
1
+ 0.3.1
@@ -66,7 +66,11 @@ module Runnable
66
66
  commands[name] = { :blocking => blocking }
67
67
 
68
68
  define_method( name ) do |*args|
69
- run name, block.call(*args), log_path
69
+ if block
70
+ run name, block.call(*args), log_path
71
+ else
72
+ run name, nil, log_path
73
+ end
70
74
  join if blocking
71
75
  end
72
76
  end
@@ -481,10 +485,10 @@ module Runnable
481
485
  end
482
486
 
483
487
  def threaded_output_processor(output_name, pipes, stream_processors)
484
- exception_processors = stream_processors.is_a?(Hash) ? stream_processors[:exceptions] : {}
488
+ exception_processors = stream_processors[:exceptions].is_a?(Hash) ? stream_processors[:exceptions] : {}
485
489
  exception_processors.merge!(self.class.processors[:exceptions] || {})
486
490
 
487
- output_processors = stream_processors.is_a?(Hash) ? stream_processors[:outputs] : {}
491
+ output_processors = stream_processors[:outputs].is_a?(Hash) ? stream_processors[:outputs] : {}
488
492
  output_processors.merge!(self.class.processors[:output] || {})
489
493
 
490
494
  Thread.new do
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{runnable}
8
- s.version = "0.3.0"
8
+ s.version = "0.3.1"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Rafael García", "Luis Ciudad", "Pedro Navajas", "Javier Aranda"]
12
- s.date = %q{2012-01-17}
12
+ s.date = %q{2012-01-23}
13
13
  s.description = %q{Convert a executable command in a Ruby-like class you are able to start, define params and send signals (like kill, or stop)}
14
14
  s.email = ["rgarcia@nosolosoftware.biz", "lciudad@nosolosoftware.biz", "pnavajas@nosolosoftware.biz", "jaranda@nosolosoftware.biz"]
15
15
  s.extra_rdoc_files = [
metadata CHANGED
@@ -1,11 +1,11 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: runnable
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  segments:
6
6
  - 0
7
7
  - 3
8
- - 0
8
+ - 1
9
9
  prerelease: false
10
10
  segments_generated: true
11
11
  platform: ruby
@@ -17,12 +17,12 @@ authors:
17
17
  autorequire: !!null
18
18
  bindir: bin
19
19
  cert_chain: []
20
- date: 2012-01-17 00:00:00.000000000 +01:00
20
+ date: 2012-01-23 00:00:00.000000000 +01:00
21
21
  default_executable: !!null
22
22
  dependencies:
23
23
  - !ruby/object:Gem::Dependency
24
24
  name: rake
25
- requirement: &32400380 !ruby/object:Gem::Requirement
25
+ requirement: &12354140 !ruby/object:Gem::Requirement
26
26
  none: false
27
27
  requirements:
28
28
  - - ! '>='
@@ -35,10 +35,10 @@ dependencies:
35
35
  segments_generated: true
36
36
  type: :development
37
37
  prerelease: false
38
- version_requirements: *32400380
38
+ version_requirements: *12354140
39
39
  - !ruby/object:Gem::Dependency
40
40
  name: yard
41
- requirement: &32398960 !ruby/object:Gem::Requirement
41
+ requirement: &12347400 !ruby/object:Gem::Requirement
42
42
  none: false
43
43
  requirements:
44
44
  - - ! '>='
@@ -51,10 +51,10 @@ dependencies:
51
51
  segments_generated: true
52
52
  type: :development
53
53
  prerelease: false
54
- version_requirements: *32398960
54
+ version_requirements: *12347400
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: rspec
57
- requirement: &32397820 !ruby/object:Gem::Requirement
57
+ requirement: &12344080 !ruby/object:Gem::Requirement
58
58
  none: false
59
59
  requirements:
60
60
  - - ! '>='
@@ -67,10 +67,10 @@ dependencies:
67
67
  segments_generated: true
68
68
  type: :development
69
69
  prerelease: false
70
- version_requirements: *32397820
70
+ version_requirements: *12344080
71
71
  - !ruby/object:Gem::Dependency
72
72
  name: cucumber
73
- requirement: &32396420 !ruby/object:Gem::Requirement
73
+ requirement: &12338600 !ruby/object:Gem::Requirement
74
74
  none: false
75
75
  requirements:
76
76
  - - ! '>='
@@ -83,10 +83,10 @@ dependencies:
83
83
  segments_generated: true
84
84
  type: :development
85
85
  prerelease: false
86
- version_requirements: *32396420
86
+ version_requirements: *12338600
87
87
  - !ruby/object:Gem::Dependency
88
88
  name: jeweler
89
- requirement: &32388060 !ruby/object:Gem::Requirement
89
+ requirement: &12308080 !ruby/object:Gem::Requirement
90
90
  none: false
91
91
  requirements:
92
92
  - - ! '>='
@@ -99,10 +99,10 @@ dependencies:
99
99
  segments_generated: true
100
100
  type: :development
101
101
  prerelease: false
102
- version_requirements: *32388060
102
+ version_requirements: *12308080
103
103
  - !ruby/object:Gem::Dependency
104
104
  name: bluecloth
105
- requirement: &32386220 !ruby/object:Gem::Requirement
105
+ requirement: &12304300 !ruby/object:Gem::Requirement
106
106
  none: false
107
107
  requirements:
108
108
  - - ! '>='
@@ -115,7 +115,7 @@ dependencies:
115
115
  segments_generated: true
116
116
  type: :development
117
117
  prerelease: false
118
- version_requirements: *32386220
118
+ version_requirements: *12304300
119
119
  description: Convert a executable command in a Ruby-like class you are able to start,
120
120
  define params and send signals (like kill, or stop)
121
121
  email:
@@ -153,7 +153,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
153
153
  segments:
154
154
  - 0
155
155
  segments_generated: true
156
- hash: -3646317310813273179
156
+ hash: 3326155685910776314
157
157
  required_rubygems_version: !ruby/object:Gem::Requirement
158
158
  none: false
159
159
  requirements: