atk_toolbox 0.0.138 → 0.0.139

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e1fca183d8a55e40db853c94d3dd8b3e3e299c85e5ac7ff2dbda79ec9801b5d0
4
- data.tar.gz: de4210e5a7f73c9f59b2f44d0a1a9449b0ddcc3a831d135e8d0a584f1e33e352
3
+ metadata.gz: dcedfdb8a7b4ede18ef2127c4135e27a3337ed00864a77d625d1eb3c68ceb1a2
4
+ data.tar.gz: 5dc0b7c8e472e3676f6b2cd8ff7f54ab5b3b605dd201e0df652cddbb52bcd783
5
5
  SHA512:
6
- metadata.gz: 93a4d1176a611db19c2f86b61424c97b939532a15e1ee52c0cab15f44fb63275294c75ca09f17c51dfcc98faa50d18120a3d98bde8e225c32fab43767bf4d31a
7
- data.tar.gz: 9fb9bc9461beca3359136240f51a8d6ccf5a10a9f5ac217b7ffa394a7c09c62f27922d4f890b39c35513184f76993d7485b86863f6988a1bcc8a1d9480dcced1
6
+ metadata.gz: ca328d42404ad2727e719398884103b2e1c3c75a54035fa3a2df5c08afc2406c6b7f1330ab745560bd2234f9ff0c4e17d6efea72fbf4a9a49be4d24f08246945
7
+ data.tar.gz: f66f3b58e7fc3980b0a9e2feda8ab066c4a13cf59393e16bbe39a6cd735afeedab2afb98ecd8fadfddbb9d41cef017835af633a9917486ab3c6931450b11c29a
@@ -110,7 +110,7 @@ Console = Class.new do
110
110
  #
111
111
  # returns the command object, ignores errors
112
112
  #
113
- def run!(command)
113
+ def run!(command, **keyword_arguments)
114
114
  if command.is_a?(String)
115
115
  # by default return a string with stderr included
116
116
  begin
@@ -118,7 +118,9 @@ Console = Class.new do
118
118
  Process.wait(command_info.pid)
119
119
  process_info = $?
120
120
  result = CommandResult.new(command_info, process_info)
121
- puts result.read
121
+ if keyword_arguments[:silent] != true
122
+ puts result.read
123
+ end
122
124
  rescue
123
125
  process_info = $?
124
126
  result = CommandResult.new(nil, process_info)
@@ -137,7 +139,7 @@ Console = Class.new do
137
139
  #
138
140
  # returns true if successful, false/nil on error
139
141
  #
140
- def run?(command)
142
+ def run?(command, **keyword_arguments)
141
143
  if command.is_a?(String)
142
144
  return system(command)
143
145
  else
@@ -153,7 +155,7 @@ Console = Class.new do
153
155
  #
154
156
  # returns process info if successful, raises error if command failed
155
157
  #
156
- def run(command)
158
+ def run(command, **keyword_arguments)
157
159
  if command.is_a?(String)
158
160
  # by default return a string with stderr included
159
161
  begin
@@ -161,7 +163,9 @@ Console = Class.new do
161
163
  Process.wait(command_info.pid)
162
164
  process_info = $?
163
165
  result = CommandResult.new(command_info, process_info)
164
- puts result.read
166
+ if keyword_arguments[:silent] != true
167
+ puts result.read
168
+ end
165
169
  rescue
166
170
  process_info = $?
167
171
  result = CommandResult.new(nil, process_info)
@@ -1,3 +1,3 @@
1
1
  module AtkToolbox
2
- VERSION = '0.0.138'
2
+ VERSION = '0.0.139'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: atk_toolbox
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.138
4
+ version: 0.0.139
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jeff Hykin