command_utils 0.4.0 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/command_utils.rb +2 -6
- metadata +17 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 169a1a41d75f6fb75d796b16fd6bb3021d5fb8f2
|
4
|
+
data.tar.gz: 946d825a529e5ec8fafe8049d5e4fe5b0e27571a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9b2bba6b1db8f1c0fd2f0ed9c189404bf03c6297c89b31403d331454aacc4e7249def486d5407f2862046cf336c313cc619a09bb85d61982ddf60dc12c67d8b7
|
7
|
+
data.tar.gz: d9c15b78aeb9cef2fca41382ebbf6984a94a144760b74bc3765ec90902a266ce95943fee43084890001d6799605f720d43e980f1bdaf30e75bc4ae1546a9b54a
|
data/lib/command_utils.rb
CHANGED
@@ -12,10 +12,7 @@ class CommandUtils
|
|
12
12
|
# Takes command in same format supported by Process#spawn.
|
13
13
|
def initialize *args
|
14
14
|
first = args.first
|
15
|
-
if first.
|
16
|
-
@env = args.shift
|
17
|
-
@command = args
|
18
|
-
elsif first.respond_to? :to_hash
|
15
|
+
if first.respond_to? :to_hash
|
19
16
|
@env = args.shift.to_hash
|
20
17
|
@command = args
|
21
18
|
else
|
@@ -166,8 +163,7 @@ class CommandUtils
|
|
166
163
|
|
167
164
|
# Wait for process termination, then process its status.
|
168
165
|
def process_status
|
169
|
-
|
170
|
-
pid, status = Process.wait2(@pid, flags)
|
166
|
+
pid, status = Process.wait2(@pid)
|
171
167
|
if status.exited?
|
172
168
|
unless status.exitstatus == 0
|
173
169
|
message = "Command exited with #{status.exitstatus}."
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: command_utils
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fabio Pugliese Ornellas
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-07-
|
11
|
+
date: 2015-07-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|
@@ -58,6 +58,20 @@ dependencies:
|
|
58
58
|
- - "~>"
|
59
59
|
- !ruby/object:Gem::Version
|
60
60
|
version: '4.6'
|
61
|
+
- !ruby/object:Gem::Dependency
|
62
|
+
name: simplecov
|
63
|
+
requirement: !ruby/object:Gem::Requirement
|
64
|
+
requirements:
|
65
|
+
- - "~>"
|
66
|
+
- !ruby/object:Gem::Version
|
67
|
+
version: '0.10'
|
68
|
+
type: :development
|
69
|
+
prerelease: false
|
70
|
+
version_requirements: !ruby/object:Gem::Requirement
|
71
|
+
requirements:
|
72
|
+
- - "~>"
|
73
|
+
- !ruby/object:Gem::Version
|
74
|
+
version: '0.10'
|
61
75
|
description: This Gem will help you call external commands, process its stdout and
|
62
76
|
stderr, to your own fit, and at the end, validate its return code.
|
63
77
|
email: fabio.ornellas@gmail.com
|
@@ -92,3 +106,4 @@ signing_key:
|
|
92
106
|
specification_version: 4
|
93
107
|
summary: Simple Gem to assist running external commands an processing its outputs.
|
94
108
|
test_files: []
|
109
|
+
has_rdoc:
|