gemsmith 19.2.0 → 19.4.0

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: 41956b20ba858bc0ae3da345b039750c494099e2fc21aa2077fe81d251b40c8c
4
- data.tar.gz: cd7db471fa963d73c8df4850846924e51cde34069ac2b7f49e35601d00f08dde
3
+ metadata.gz: 588af59f585464b95ba8f2d2ec07458dbc2a8d89e3ebb52ecd737e39b3c00675
4
+ data.tar.gz: f92b0e9930f9f57073f58fba4fc95515868f1fdd5a7884e007ea4af7da27ebb9
5
5
  SHA512:
6
- metadata.gz: 1894e7adc3d06f444a05497f220dba00c72422c20e883721771d9b8b48a69cf37ead61b11b29e3a221d5a67071371b891f3252ac4543c8ff6ac633208c7ae0cc
7
- data.tar.gz: be4fe741216bbb16cae41cce3e99bd76ff675dff9ccc266a4abc868f69282ec151885f742afda81e423cec484394e8ef23dc5e9368dda8e33e1d6f5c3333e091
6
+ metadata.gz: a6357327f0ffa8bacde163adbb5685b9c2a837745c60edffe0fef878f0b9f000a984c9eeb63f61de8e80fe7b606c88c858d377402f53cb1172349035d3be2854
7
+ data.tar.gz: 61abc9c64eddb6fc10a049bac0be3a025fb104c30db331416f02fa688bdde66157bb56f5fd5a4bae65fceab41f07d736577d4a7be62e8c84972df9654769232a
checksums.yaml.gz.sig CHANGED
@@ -1,4 +1 @@
1
- ��"
2
- q���.��l4��
3
- #�Jq:
4
- �88�f)�#�,�YXL?���G�;·��5
1
+ �|�áY� �a���dO9N-�z�|�Lʋ�TK�������랫
data/README.adoc CHANGED
@@ -525,7 +525,7 @@ To test, run:
525
525
 
526
526
  [source,bash]
527
527
  ----
528
- bundle exec rake
528
+ bin/rake
529
529
  ----
530
530
 
531
531
  == link:https://www.alchemists.io/policies/license[License]
data/gemsmith.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = "gemsmith"
5
- spec.version = "19.2.0"
5
+ spec.version = "19.4.0"
6
6
  spec.authors = ["Brooke Kuhlmann"]
7
7
  spec.email = ["brooke@alchemists.io"]
8
8
  spec.homepage = "https://www.alchemists.io/projects/gemsmith"
@@ -30,7 +30,7 @@ Gem::Specification.new do |spec|
30
30
  spec.add_dependency "infusible", "~> 1.0"
31
31
  spec.add_dependency "milestoner", "~> 15.2"
32
32
  spec.add_dependency "refinements", "~> 10.0"
33
- spec.add_dependency "rubysmith", "~> 4.3"
33
+ spec.add_dependency "rubysmith", "~> 4.5"
34
34
  spec.add_dependency "runcom", "~> 9.0"
35
35
  spec.add_dependency "spek", "~> 1.0"
36
36
  spec.add_dependency "versionaire", "~> 11.0"
@@ -4,41 +4,8 @@ module Gemsmith
4
4
  module Builders
5
5
  module Git
6
6
  # Builds project skeleton initial Git commit message.
7
- class Commit
7
+ class Commit < Rubysmith::Builders::Git::Commit
8
8
  include Import[:specification]
9
-
10
- def self.call(...) = new(...).call
11
-
12
- def initialize configuration, builder: Rubysmith::Builder, **dependencies
13
- super(**dependencies)
14
-
15
- @configuration = configuration
16
- @builder = builder
17
- end
18
-
19
- def call
20
- return configuration unless configuration.build_git
21
-
22
- builder.call(configuration)
23
- .run("git add .", chdir: project_name)
24
- .run(
25
- %(git commit --all --message "Added project skeleton" --message "#{body}"),
26
- chdir: project_name
27
- )
28
-
29
- configuration
30
- end
31
-
32
- private
33
-
34
- attr_reader :configuration, :builder
35
-
36
- def body
37
- "Generated with [#{specification.label}](#{specification.homepage_url}) " \
38
- "#{specification.version}."
39
- end
40
-
41
- def project_name = configuration.project_name
42
9
  end
43
10
  end
44
11
  end
@@ -43,8 +43,8 @@ module Gemsmith
43
43
  Builders::Git::Commit
44
44
  ].freeze
45
45
 
46
- def initialize builders: BUILDERS, **dependencies
47
- super(**dependencies)
46
+ def initialize(builders: BUILDERS, **)
47
+ super(**)
48
48
  @builders = builders
49
49
  end
50
50
 
@@ -7,9 +7,8 @@ module Gemsmith
7
7
  class Config
8
8
  include Gemsmith::Import[:kernel, :logger]
9
9
 
10
- def initialize client: Configuration::Loader::CLIENT, **dependencies
11
- super(**dependencies)
12
-
10
+ def initialize(client: Configuration::Loader::CLIENT, **)
11
+ super(**)
13
12
  @client = client
14
13
  end
15
14
 
@@ -11,9 +11,8 @@ module Gemsmith
11
11
  include Gemsmith::Import[:kernel, :logger]
12
12
  include Dry::Monads[:result]
13
13
 
14
- def initialize picker: Spek::Picker, editor: Tools::Editor.new, **dependencies
15
- super(**dependencies)
16
-
14
+ def initialize(picker: Spek::Picker, editor: Tools::Editor.new, **)
15
+ super(**)
17
16
  @picker = picker
18
17
  @editor = editor
19
18
  end
@@ -11,9 +11,8 @@ module Gemsmith
11
11
  include Gemsmith::Import[:logger]
12
12
  include Dry::Monads[:result]
13
13
 
14
- def initialize installer: Tools::Installer.new, loader: Spek::Loader, **dependencies
15
- super(**dependencies)
16
-
14
+ def initialize(installer: Tools::Installer.new, loader: Spek::Loader, **)
15
+ super(**)
17
16
  @installer = installer
18
17
  @loader = loader
19
18
  end
@@ -11,9 +11,8 @@ module Gemsmith
11
11
  include Gemsmith::Import[:logger]
12
12
  include Dry::Monads[:result]
13
13
 
14
- def initialize publisher: Tools::Publisher.new, loader: Spek::Loader, **dependencies
15
- super(**dependencies)
16
-
14
+ def initialize(publisher: Tools::Publisher.new, loader: Spek::Loader, **)
15
+ super(**)
17
16
  @publisher = publisher
18
17
  @loader = loader
19
18
  end
@@ -11,9 +11,8 @@ module Gemsmith
11
11
  include Gemsmith::Import[:kernel, :logger]
12
12
  include Dry::Monads[:result]
13
13
 
14
- def initialize picker: Spek::Picker, viewer: Tools::Viewer.new, **dependencies
15
- super(**dependencies)
16
-
14
+ def initialize(picker: Spek::Picker, viewer: Tools::Viewer.new, **)
15
+ super(**)
17
16
  @picker = picker
18
17
  @viewer = viewer
19
18
  end
@@ -14,9 +14,8 @@ module Gemsmith
14
14
  # Order is important.
15
15
  SECTIONS = [Parsers::Core, Rubysmith::CLI::Parsers::Build, Parsers::Build].freeze
16
16
 
17
- def initialize sections: SECTIONS, client: CLIENT, **dependencies
18
- super(**dependencies)
19
-
17
+ def initialize(sections: SECTIONS, client: CLIENT, **)
18
+ super(**)
20
19
  @sections = sections
21
20
  @client = client
22
21
  @configuration_duplicate = configuration.dup
@@ -14,12 +14,8 @@ module Gemsmith
14
14
 
15
15
  def self.call(...) = new(...).call
16
16
 
17
- def initialize configuration = Container[:configuration],
18
- client: Parser::CLIENT,
19
- **dependencies
20
-
21
- super(**dependencies)
22
-
17
+ def initialize(configuration = Container[:configuration], client: Parser::CLIENT, **)
18
+ super(**)
23
19
  @configuration = configuration
24
20
  @client = client
25
21
  end
@@ -15,11 +15,8 @@ module Gemsmith
15
15
 
16
16
  def self.call(...) = new(...).call
17
17
 
18
- def initialize configuration = Container[:configuration],
19
- client: Parser::CLIENT,
20
- **dependencies
21
- super(**dependencies)
22
-
18
+ def initialize(configuration = Container[:configuration], client: Parser::CLIENT, **)
19
+ super(**)
23
20
  @configuration = configuration
24
21
  @client = client
25
22
  end
@@ -17,13 +17,13 @@ module Gemsmith
17
17
  :logger
18
18
  ]
19
19
 
20
- def initialize parser: Parser.new, **dependencies
21
- super(**dependencies)
20
+ def initialize(parser: Parser.new, **)
21
+ super(**)
22
22
  @parser = parser
23
23
  end
24
24
 
25
25
  def call arguments = Core::EMPTY_ARRAY
26
- perform parser.call(arguments)
26
+ act_on parser.call(arguments)
27
27
  rescue OptionParser::ParseError => error
28
28
  logger.error { error.message }
29
29
  end
@@ -32,7 +32,7 @@ module Gemsmith
32
32
 
33
33
  attr_reader :parser
34
34
 
35
- def perform configuration
35
+ def act_on configuration
36
36
  case configuration
37
37
  in action_config: Symbol => action then config.call action
38
38
  in action_build: true then build.call configuration
@@ -1,14 +1,11 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require "refinements/structs"
4
3
  require "runcom"
5
4
 
6
5
  module Gemsmith
7
6
  module Configuration
8
7
  # Represents the fully assembled Command Line Interface (CLI) configuration.
9
8
  class Loader < Rubysmith::Configuration::Loader
10
- using Refinements::Structs
11
-
12
9
  DEFAULTS = Rubysmith::Configuration::Loader::DEFAULTS
13
10
  CLIENT = Runcom::Config.new "gemsmith/configuration.yml", defaults: DEFAULTS
14
11
 
@@ -17,9 +14,7 @@ module Gemsmith
17
14
  enhancers: {template_root: Rubysmith::Configuration::Enhancers::TemplateRoot}
18
15
  end
19
16
 
20
- def initialize client: CLIENT, **dependencies
21
- super
22
- end
17
+ def initialize(client: CLIENT, **) = super
23
18
 
24
19
  def call
25
20
  return super unless enhancers.key? :template_root
@@ -5,9 +5,8 @@
5
5
  class Config
6
6
  include <%= configuration.project_class %>::Import[:kernel, :logger]
7
7
 
8
- def initialize client: Configuration::Loader::CLIENT, **dependencies
9
- super(**dependencies)
10
-
8
+ def initialize(client: Configuration::Loader::CLIENT, **)
9
+ super(**)
11
10
  @client = client
12
11
  end
13
12
 
@@ -12,9 +12,8 @@ require "optparse"
12
12
  # Order is important.
13
13
  SECTIONS = [Parsers::Core].freeze
14
14
 
15
- def initialize sections: SECTIONS, client: CLIENT, **dependencies
16
- super(**dependencies)
17
-
15
+ def initialize(sections: SECTIONS, client: CLIENT, **)
16
+ super(**)
18
17
  @sections = sections
19
18
  @client = client
20
19
  @configuration_duplicate = configuration.dup
@@ -12,11 +12,8 @@ require "refinements/structs"
12
12
 
13
13
  def self.call(...) = new(...).call
14
14
 
15
- def initialize configuration = Container[:configuration],
16
- client: Parser::CLIENT,
17
- **dependencies
18
-
19
- super(**dependencies)
15
+ def initialize(configuration = Container[:configuration], client: Parser::CLIENT, **)
16
+ super(**)
20
17
  @configuration = configuration
21
18
  @client = client
22
19
  end
@@ -6,13 +6,13 @@ require "core"
6
6
  class Shell
7
7
  include Actions::Import[:config, :specification, :logger]
8
8
 
9
- def initialize parser: Parser.new, **dependencies
10
- super(**dependencies)
9
+ def initialize(parser: Parser.new, **)
10
+ super(**)
11
11
  @parser = parser
12
12
  end
13
13
 
14
14
  def call arguments = Core::EMPTY_ARRAY
15
- perform parser.call(arguments)
15
+ act_on parser.call(arguments)
16
16
  rescue OptionParser::ParseError => error
17
17
  logger.error { error.message }
18
18
  end
@@ -21,7 +21,7 @@ require "core"
21
21
 
22
22
  attr_reader :parser
23
23
 
24
- def perform configuration
24
+ def act_on configuration
25
25
  case configuration
26
26
  in action_config: Symbol => action then config.call action
27
27
  in action_version: true then logger.info { specification.labeled_version }
@@ -12,9 +12,8 @@ module Gemsmith
12
12
  # Order matters.
13
13
  STEPS = [Tools::Cleaner.new, Tools::Packager.new].freeze
14
14
 
15
- def initialize steps: STEPS, **dependencies
16
- super(**dependencies)
17
-
15
+ def initialize(steps: STEPS, **)
16
+ super(**)
18
17
  @steps = steps
19
18
  end
20
19
 
@@ -10,9 +10,8 @@ module Gemsmith
10
10
  include Import[:executor, :logger]
11
11
  include Dry::Monads[:result]
12
12
 
13
- def initialize command: Gem::CommandManager.new, **dependencies
14
- super(**dependencies)
15
-
13
+ def initialize(command: Gem::CommandManager.new, **)
14
+ super(**)
16
15
  @command = command
17
16
  end
18
17
 
@@ -10,12 +10,12 @@ module Gemsmith
10
10
  include Import[:configuration]
11
11
  include Dry::Monads[:result]
12
12
 
13
- def initialize client: Milestoner::Tags::Publisher.new,
14
- content: Milestoner::Configuration::Content,
15
- **dependencies
16
-
17
- super(**dependencies)
18
-
13
+ def initialize(
14
+ client: Milestoner::Tags::Publisher.new,
15
+ content: Milestoner::Configuration::Content,
16
+ **
17
+ )
18
+ super(**)
19
19
  @client = client
20
20
  @content = content
21
21
  end
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gemsmith
3
3
  version: !ruby/object:Gem::Version
4
- version: 19.2.0
4
+ version: 19.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brooke Kuhlmann
@@ -28,7 +28,7 @@ cert_chain:
28
28
  CxDe2+VuChj4I1nvIHdu+E6XoEVlanUPKmSg6nddhkKn2gC45Kyzh6FZqnzH/CRp
29
29
  RFE=
30
30
  -----END CERTIFICATE-----
31
- date: 2023-01-08 00:00:00.000000000 Z
31
+ date: 2023-02-05 00:00:00.000000000 Z
32
32
  dependencies:
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: cogger
@@ -134,14 +134,14 @@ dependencies:
134
134
  requirements:
135
135
  - - "~>"
136
136
  - !ruby/object:Gem::Version
137
- version: '4.3'
137
+ version: '4.5'
138
138
  type: :runtime
139
139
  prerelease: false
140
140
  version_requirements: !ruby/object:Gem::Requirement
141
141
  requirements:
142
142
  - - "~>"
143
143
  - !ruby/object:Gem::Version
144
- version: '4.3'
144
+ version: '4.5'
145
145
  - !ruby/object:Gem::Dependency
146
146
  name: runcom
147
147
  requirement: !ruby/object:Gem::Requirement
@@ -293,7 +293,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
293
293
  - !ruby/object:Gem::Version
294
294
  version: '0'
295
295
  requirements: []
296
- rubygems_version: 3.4.2
296
+ rubygems_version: 3.4.6
297
297
  signing_key:
298
298
  specification_version: 4
299
299
  summary: A command line interface for smithing Ruby gems.
metadata.gz.sig CHANGED
Binary file