scmd 3.0.4 → 3.0.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 67125e428f1adb1fe7f302c3d0276a0384d5b41a74be0a40b52256043dc22632
4
- data.tar.gz: c1dcc9b7152046ff0a5af224acc3c31f3124c423e818d048f8879310d2b9d645
3
+ metadata.gz: f93aa47368dbe362f4e21f275f29e463e1be3ac7a4eec07b5ce2d18b77155543
4
+ data.tar.gz: 3d9daf1670226711e0852c079276823f211088eb306e7b147b8bba140d5aee74
5
5
  SHA512:
6
- metadata.gz: 74b33660ba6eab558d637797e1e03ec67607a0110be680822a22851fa7068d14b60a4d8f2fb1ff58ad1867f1c964bd34c619838efa7187c775eb491b6cef04c3
7
- data.tar.gz: 17ea7892c22832d00868a8b9659ba8aabfc57b1c0c3df0a91e41a929d47af039ac40110b3a3b58a3688e09db61a42a531b68903a23f0ec4c8e978bec8deb3002
6
+ metadata.gz: 6aab5d881aa873b1f95309ecd760a2e04e349df5821b3ac8814e5a4aba0fbe95e38aa6638cd3f9b5b70e0fea410b93a1aba65c78bf82ac8223b33514f9740616
7
+ data.tar.gz: 4a167c35519b264b3c33c93c72315af1f73f50c8b0b3373fb59946dcd95dbd5d93046d4978560ee1568a9cedd241487df27d986607ae6cc31373136fc179fd88
data/Gemfile CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  source "https://rubygems.org"
4
4
 
5
+ ruby ">= 2.5"
6
+
5
7
  gemspec
6
8
 
7
9
  gem "pry"
@@ -9,3 +11,9 @@ gem "whysoslow"
9
11
 
10
12
  # to release, uncomment this and run `bundle exec ggem r -f`
11
13
  gem 'ggem'
14
+
15
+ gem "assert", path: "/Users/kellyredding/projects/tmp/assert"
16
+ gem "much-style-guide", path: "/Users/kellyredding/projects/tmp/much-style-guide"
17
+ gem "much-factory", path: "/Users/kellyredding/projects/tmp/much-factory"
18
+ gem "much-not-given", path: "/Users/kellyredding/projects/tmp/much-not-given"
19
+ gem "much-stub", path: "/Users/kellyredding/projects/tmp/much-stub"
data/bench/runner.rb CHANGED
@@ -12,9 +12,10 @@ class ScmdBenchRunner
12
12
 
13
13
  def initialize(printer_io, cmd, num_times = 10)
14
14
  @cmd = cmd
15
- @proc = proc do
16
- num_times.times{ cmd.run! }
17
- end
15
+ @proc =
16
+ proc do
17
+ num_times.times{ cmd.run! }
18
+ end
18
19
 
19
20
  @printer =
20
21
  Whysoslow::DefaultPrinter.new(
data/lib/scmd/command.rb CHANGED
@@ -56,15 +56,16 @@ module Scmd
56
56
 
57
57
  @pid = @child_process.pid.to_i
58
58
  @child_process.write(input)
59
- @read_output_thread = Thread.new do
60
- while @child_process.check_for_exit
61
- begin
62
- read_output
63
- rescue EOFError # rubocop:disable Lint/SuppressedException
59
+ @read_output_thread =
60
+ Thread.new do
61
+ while @child_process.check_for_exit
62
+ begin
63
+ read_output
64
+ rescue EOFError # rubocop:disable Lint/SuppressedException
65
+ end
64
66
  end
67
+ @stop_w.write_nonblock(".")
65
68
  end
66
- @stop_w.write_nonblock(".")
67
- end
68
69
  end
69
70
 
70
71
  def wait(timeout = nil)
@@ -168,7 +169,7 @@ module Scmd
168
169
  end
169
170
 
170
171
  def stringify_hash(hash)
171
- hash.inject({}) do |h, (k, v)|
172
+ hash.reduce({}) do |h, (k, v)|
172
173
  h.merge(k.to_s => v.to_s)
173
174
  end
174
175
  end
data/lib/scmd/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Scmd
4
- VERSION = "3.0.4"
4
+ VERSION = "3.0.5"
5
5
  end
data/lib/scmd.rb CHANGED
@@ -19,10 +19,11 @@ module Scmd
19
19
 
20
20
  def self.commands
21
21
  raise NoMethodError unless ENV["SCMD_TEST_MODE"]
22
- @commands ||= begin
23
- require "scmd/stored_commands"
24
- StoredCommands.new
25
- end
22
+ @commands ||=
23
+ begin
24
+ require "scmd/stored_commands"
25
+ StoredCommands.new
26
+ end
26
27
  end
27
28
 
28
29
  def self.calls
data/scmd.gemspec CHANGED
@@ -21,6 +21,8 @@ Gem::Specification.new do |gem|
21
21
  gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
22
22
  gem.require_paths = ["lib"]
23
23
 
24
+ gem.required_ruby_version = ">= 2.5"
25
+
24
26
  gem.add_development_dependency("much-style-guide", ["~> 0.6.0"])
25
27
  gem.add_development_dependency("assert", ["~> 2.19.2"])
26
28
 
metadata CHANGED
@@ -1,15 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: scmd
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.4
4
+ version: 3.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kelly Redding
8
8
  - Collin Redding
9
- autorequire:
9
+ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2021-01-10 00:00:00.000000000 Z
12
+ date: 2021-10-28 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: much-style-guide
@@ -88,7 +88,7 @@ homepage: http://github.com/redding/scmd
88
88
  licenses:
89
89
  - MIT
90
90
  metadata: {}
91
- post_install_message:
91
+ post_install_message:
92
92
  rdoc_options: []
93
93
  require_paths:
94
94
  - lib
@@ -96,15 +96,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
96
96
  requirements:
97
97
  - - ">="
98
98
  - !ruby/object:Gem::Version
99
- version: '0'
99
+ version: '2.5'
100
100
  required_rubygems_version: !ruby/object:Gem::Requirement
101
101
  requirements:
102
102
  - - ">="
103
103
  - !ruby/object:Gem::Version
104
104
  version: '0'
105
105
  requirements: []
106
- rubygems_version: 3.2.4
107
- signing_key:
106
+ rubygems_version: 3.2.29
107
+ signing_key:
108
108
  specification_version: 4
109
109
  summary: Build and run system commands.
110
110
  test_files: