rubysmith 0.8.0 → 0.9.0

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: cc49110ec0c6a64e8a61c955db7e7019df90dc35058f29b5d1fb88b66ddbe6b1
4
- data.tar.gz: 04cf9523178bd4510f596089e560444e5bcfbe500f01e152d27d02068aaab200
3
+ metadata.gz: 35f0eea5be27d1e8a8e05430c6b99d80bfa02bbeabbc6e1148f4c7b388280a26
4
+ data.tar.gz: ebce4666b017291222012d583ce61266cd15674bf6248199e6cff1700484d4fd
5
5
  SHA512:
6
- metadata.gz: 0dc3eb2629ad86d42a4dea655b9460930dc671e27be1f9cacf424e66e89f2b396406944715b243d375d578cadb5fbc6d4996f4a8d30da8139881555f78f4ff27
7
- data.tar.gz: 421f8be12cb1c8a9445c3b9d6913f455ce041612f082aba3f4b5b9758c877a5b4f069d1fa202804c02d7c71eef630419eebae19551bb49a140ab9d82f7bac26e
6
+ metadata.gz: be592ad7f91f4589ba1aac09b26a7ff875edbc36974559abdae1410e0e41342f08dd5ff24c6517ff63eb87af30491a86115c165c161a39bb3b6453f315230a13
7
+ data.tar.gz: d245861a8bf50f49541dd9f0aae53007681905eebff6d561ac3a7a9d0fc70ccfa495233fa2f0764cb44313e8f2d0569130ef007e2d63468d587c455e9c3a8035
Binary file
data.tar.gz.sig CHANGED
Binary file
@@ -1,9 +1,6 @@
1
1
  #! /usr/bin/env ruby
2
2
  # frozen_string_literal: true
3
3
 
4
- # TODO: Remove once the Pattern Matching feature is fully supported.
5
- Warning[:experimental] = false
6
-
7
4
  require "rubysmith"
8
5
  require "rubysmith/cli/shell"
9
6
 
@@ -2,19 +2,22 @@
2
2
 
3
3
  require "bundler"
4
4
  require "bundler/cli"
5
+ require "refinements/pathnames"
5
6
 
6
7
  module Rubysmith
7
8
  module Builders
8
9
  # Builds Bundler Gemfile configuration and installs gem dependencies for project skeleton.
9
10
  class Bundler
11
+ using Refinements::Pathnames
12
+
10
13
  def self.call realm, builder: Builder
11
14
  new(realm, builder: builder).call
12
15
  end
13
16
 
14
- def initialize realm, builder: Builder, runner: ::Bundler::CLI
17
+ def initialize realm, builder: Builder, client: ::Bundler::CLI
15
18
  @realm = realm
16
19
  @builder = builder
17
- @runner = runner
20
+ @client = client
18
21
  end
19
22
 
20
23
  def call
@@ -26,13 +29,14 @@ module Rubysmith
26
29
  .replace(/(\n+|\s+)end/, "\nend")
27
30
  .replace(/\n\ngroup :(code_quality|test|tools) do\nend/, "")
28
31
  .replace(/org"\n+/, "org\"\n\n")
29
- Dir.chdir(realm.project_root) { runner.start %w[install --quiet] }
32
+
33
+ realm.project_root.change_dir { client.start %w[install --quiet] }
30
34
  nil
31
35
  end
32
36
 
33
37
  private
34
38
 
35
- attr_reader :realm, :builder, :runner
39
+ attr_reader :realm, :builder, :client
36
40
  end
37
41
  end
38
42
  end
@@ -10,19 +10,19 @@ module Rubysmith
10
10
  new(realm).call
11
11
  end
12
12
 
13
- def initialize realm, runner: Pragmater::Runner
13
+ def initialize realm, client: Pragmater::Runner
14
14
  @realm = realm
15
- @runner = runner
15
+ @client = client
16
16
  end
17
17
 
18
18
  def call
19
- runner.for(**attributes).call
19
+ client.for(**attributes).call
20
20
  nil
21
21
  end
22
22
 
23
23
  private
24
24
 
25
- attr_reader :realm, :runner
25
+ attr_reader :realm, :client
26
26
 
27
27
  def attributes
28
28
  {
@@ -4,7 +4,7 @@ module Rubysmith
4
4
  module Identity
5
5
  NAME = "rubysmith"
6
6
  LABEL = "Rubysmith"
7
- VERSION = "0.8.0"
7
+ VERSION = "0.9.0"
8
8
  VERSION_LABEL = "#{LABEL} #{VERSION}"
9
9
  SUMMARY = "A command line interface for smithing Ruby projects."
10
10
  end
@@ -1,3 +1,5 @@
1
+ ruby File.read(".ruby-version").strip
2
+
1
3
  source "https://rubygems.org"
2
4
 
3
5
  <% unless realm.build_minimum %>
@@ -19,7 +21,7 @@ source "https://rubygems.org"
19
21
  gem "reek", "~> 6.0"
20
22
  <% end %>
21
23
  <% if realm.build_rubocop %>
22
- gem "rubocop", "~> 1.5"
24
+ gem "rubocop", "~> 1.8"
23
25
  gem "rubocop-performance", "~> 1.9"
24
26
  gem "rubocop-rake", "~> 0.5"
25
27
  <% end %>
@@ -1,4 +1,4 @@
1
- RSpec.shared_context "with temporary directory", :temp_dir do
1
+ RSpec.shared_context "with temporary directory" do
2
2
  <% if realm.build_refinements %>using Refinements::Pathnames<% end %>
3
3
 
4
4
  let(:temp_dir) { Bundler.root.join "tmp/rspec" }
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rubysmith
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.0
4
+ version: 0.9.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brooke Kuhlmann
@@ -28,7 +28,7 @@ cert_chain:
28
28
  2XV8FRa7/JimI07sPLC13eLY3xd/aYTi85Z782KIA4j0G8XEEWAX0ouBhlXPocZv
29
29
  QWc=
30
30
  -----END CERTIFICATE-----
31
- date: 2020-12-30 00:00:00.000000000 Z
31
+ date: 2021-01-24 00:00:00.000000000 Z
32
32
  dependencies:
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: pragmater
@@ -64,14 +64,14 @@ dependencies:
64
64
  requirements:
65
65
  - - "~>"
66
66
  - !ruby/object:Gem::Version
67
- version: '1.5'
67
+ version: '1.8'
68
68
  type: :runtime
69
69
  prerelease: false
70
70
  version_requirements: !ruby/object:Gem::Requirement
71
71
  requirements:
72
72
  - - "~>"
73
73
  - !ruby/object:Gem::Version
74
- version: '1.5'
74
+ version: '1.8'
75
75
  - !ruby/object:Gem::Dependency
76
76
  name: runcom
77
77
  requirement: !ruby/object:Gem::Requirement
@@ -180,7 +180,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
180
180
  - !ruby/object:Gem::Version
181
181
  version: '0'
182
182
  requirements: []
183
- rubygems_version: 3.2.3
183
+ rubygems_version: 3.2.6
184
184
  signing_key:
185
185
  specification_version: 4
186
186
  summary: A command line interface for smithing Ruby projects.
metadata.gz.sig CHANGED
Binary file