gemsmith 20.2.0 → 20.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/README.adoc +1 -21
- data/exe/gemsmith +1 -1
- data/gemsmith.gemspec +2 -2
- data/lib/gemsmith/cli/actions/install.rb +2 -2
- data/lib/gemsmith/cli/actions/publish.rb +2 -2
- data/lib/gemsmith/cli/shell.rb +0 -3
- data/lib/gemsmith/container.rb +11 -8
- data/lib/gemsmith/templates/%project_name%/exe/%project_name%.erb +1 -1
- data/lib/gemsmith/templates/%project_name%/lib/%project_path%/container.rb.erb +10 -7
- data.tar.gz.sig +0 -0
- metadata +5 -5
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8869cf7c922df0fad49e6439159c059dad5d0a2e14e9fef55153cc95f3c155f5
|
4
|
+
data.tar.gz: 55fdbffe5e0f6eb70eb3c03bdbb7fa35a30abfd7517f7d5c14f55d0c4e322505
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b0ddd3476054d375abdb1b373ebbdf4cfa384b0897fb31b9fb0afd9688bee5a887d7ed90dcf5318fcfceb73cec6877ebd224014baa0527620489dd936edb329e
|
7
|
+
data.tar.gz: 06cb42377fc3ff92cc6d685351e994492c3c877f13cdd72cd14003292199a08525441a26f45d4f354f43576c5041af09ea42fa10023e2247cf17a87c5021f37f
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/README.adoc
CHANGED
@@ -52,27 +52,7 @@ gem install gemsmith
|
|
52
52
|
|
53
53
|
From the command line, type: `gemsmith --help`
|
54
54
|
|
55
|
-
|
56
|
-
USAGE
|
57
|
-
gemsmith [OPTIONS]
|
58
|
-
gemsmith COMMAND [OPTIONS]
|
59
|
-
|
60
|
-
OPTIONS
|
61
|
-
-i, --install [GEM] Install gem for local development.
|
62
|
-
Optionally computes gem package based on current directory.
|
63
|
-
-p, --publish [GEM] Publish gem to remote gem server.
|
64
|
-
Optionally computes gem package based on current directory.
|
65
|
-
Default: gemsmith.
|
66
|
-
-e, --edit GEM Edit installed gem in default editor.
|
67
|
-
-V, --view GEM View installed gem in default browser.
|
68
|
-
-v, --version Show version.
|
69
|
-
-h, --help [COMMAND] Show this message.
|
70
|
-
|
71
|
-
COMMANDS
|
72
|
-
config Manage configuration.
|
73
|
-
Path is dynamic per current directory.
|
74
|
-
build Build new project.
|
75
|
-
....
|
55
|
+
image:https://alchemists.io/images/projects/gemsmith/screenshots/usage.png[Usage,width=729,height=462,role=focal_point]
|
76
56
|
|
77
57
|
==== Build
|
78
58
|
|
data/exe/gemsmith
CHANGED
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 = "20.
|
5
|
+
spec.version = "20.3.0"
|
6
6
|
spec.authors = ["Brooke Kuhlmann"]
|
7
7
|
spec.email = ["brooke@alchemists.io"]
|
8
8
|
spec.homepage = "https://alchemists.io/projects/gemsmith"
|
@@ -32,7 +32,7 @@ Gem::Specification.new do |spec|
|
|
32
32
|
spec.add_dependency "infusible", "~> 2.0"
|
33
33
|
spec.add_dependency "milestoner", "~> 16.0"
|
34
34
|
spec.add_dependency "refinements", "~> 11.0"
|
35
|
-
spec.add_dependency "rubysmith", "~> 5.
|
35
|
+
spec.add_dependency "rubysmith", "~> 5.5"
|
36
36
|
spec.add_dependency "runcom", "~> 10.0"
|
37
37
|
spec.add_dependency "sod", "~> 0.0"
|
38
38
|
spec.add_dependency "spek", "~> 2.0"
|
@@ -27,8 +27,8 @@ module Gemsmith
|
|
27
27
|
@loader = loader
|
28
28
|
end
|
29
29
|
|
30
|
-
def call name =
|
31
|
-
case installer.call loader.call("#{name}.gemspec")
|
30
|
+
def call name = nil
|
31
|
+
case installer.call loader.call("#{name || default}.gemspec")
|
32
32
|
in Success(spec) then logger.info { "Installed: #{spec.package_name}." }
|
33
33
|
in Failure(message) then log_error { message }
|
34
34
|
else log_error { "Unable to handle install action." }
|
@@ -27,8 +27,8 @@ module Gemsmith
|
|
27
27
|
@loader = loader
|
28
28
|
end
|
29
29
|
|
30
|
-
def call name =
|
31
|
-
case publisher.call loader.call("#{name}.gemspec")
|
30
|
+
def call name = nil
|
31
|
+
case publisher.call loader.call("#{name || default}.gemspec")
|
32
32
|
in Success(spec) then logger.info { "Published: #{spec.package_name}." }
|
33
33
|
in Failure(message) then log_error { message }
|
34
34
|
else log_error { "Unable to handle publish action." }
|
data/lib/gemsmith/cli/shell.rb
CHANGED
@@ -20,8 +20,6 @@ module Gemsmith
|
|
20
20
|
|
21
21
|
attr_reader :context, :dsl
|
22
22
|
|
23
|
-
# :reek:TooManyStatements
|
24
|
-
# rubocop:todo Metrics/MethodLength
|
25
23
|
def cli
|
26
24
|
context = build_context
|
27
25
|
|
@@ -36,7 +34,6 @@ module Gemsmith
|
|
36
34
|
on Sod::Prefabs::Actions::Help, self
|
37
35
|
end
|
38
36
|
end
|
39
|
-
# rubocop:enable Metrics/MethodLength
|
40
37
|
|
41
38
|
def build_context
|
42
39
|
context[defaults_path:, xdg_config:, version_label: specification.labeled_version]
|
data/lib/gemsmith/container.rb
CHANGED
@@ -12,12 +12,12 @@ module Gemsmith
|
|
12
12
|
module Container
|
13
13
|
extend Dry::Container::Mixin
|
14
14
|
|
15
|
-
register :configuration do
|
15
|
+
register :configuration, memoize: true do
|
16
16
|
self[:defaults].add_loader(Etcher::Loaders::YAML.new(self[:xdg_config].active))
|
17
17
|
.then { |registry| Etcher.call registry }
|
18
18
|
end
|
19
19
|
|
20
|
-
register :defaults do
|
20
|
+
register :defaults, memoize: true do
|
21
21
|
registry = Etcher::Registry.new contract: Rubysmith::Configuration::Contract,
|
22
22
|
model: Rubysmith::Configuration::Model
|
23
23
|
|
@@ -29,19 +29,22 @@ module Gemsmith
|
|
29
29
|
.add_transformer(Rubysmith::Configuration::Transformers::TemplateRoot.new)
|
30
30
|
.add_transformer(
|
31
31
|
Rubysmith::Configuration::Transformers::TemplateRoot.new(
|
32
|
-
Pathname(__dir__).join("templates")
|
32
|
+
default: Pathname(__dir__).join("templates")
|
33
33
|
)
|
34
34
|
)
|
35
35
|
.add_transformer(Rubysmith::Configuration::Transformers::TargetRoot)
|
36
36
|
end
|
37
37
|
|
38
|
+
register :specification, memoize: true do
|
39
|
+
Spek::Loader.call "#{__dir__}/../../gemsmith.gemspec"
|
40
|
+
end
|
41
|
+
|
38
42
|
register(:input, memoize: true) { self[:configuration].dup }
|
39
43
|
register(:defaults_path) { Rubysmith::Container[:defaults_path] }
|
40
|
-
register(:xdg_config) { Runcom::Config.new "gemsmith/configuration.yml" }
|
41
|
-
register(:specification) { Spek::Loader.call "#{__dir__}/../../gemsmith.gemspec" }
|
44
|
+
register(:xdg_config, memoize: true) { Runcom::Config.new "gemsmith/configuration.yml" }
|
42
45
|
register(:environment) { ENV }
|
43
|
-
register(:
|
44
|
-
register
|
45
|
-
register
|
46
|
+
register(:logger, memoize: true) { Cogger.new formatter: :emoji }
|
47
|
+
register :executor, Open3
|
48
|
+
register :kernel, Kernel
|
46
49
|
end
|
47
50
|
end
|
@@ -9,20 +9,23 @@ require "spek"
|
|
9
9
|
module Container
|
10
10
|
extend Dry::Container::Mixin
|
11
11
|
|
12
|
-
register :configuration do
|
12
|
+
register :configuration, memoize: true do
|
13
13
|
self[:defaults].add_loader(Etcher::Loaders::YAML.new(self[:xdg_config].active))
|
14
14
|
.then { |registry| Etcher.call registry }
|
15
15
|
end
|
16
16
|
|
17
|
-
register :defaults do
|
17
|
+
register :defaults, memoize: true do
|
18
18
|
Etcher::Registry.new(contract: Configuration::Contract, model: Configuration::Model)
|
19
19
|
.add_loader(Etcher::Loaders::YAML.new(self[:defaults_path]))
|
20
20
|
end
|
21
21
|
|
22
|
-
register
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
register(:
|
22
|
+
register :specification, memoize: true do
|
23
|
+
Spek::Loader.call "#{__dir__}/<%= Array.new(2 + configuration.project_levels, "../").join %><%= configuration.project_name %>.gemspec"
|
24
|
+
end
|
25
|
+
|
26
|
+
register(:defaults_path, memoize: true) { Pathname(__dir__).join("configuration/defaults.yml") }
|
27
|
+
register(:xdg_config, memoize: true) { Runcom::Config.new "<%= configuration.project_path %>/configuration.yml" }
|
28
|
+
register(:logger, memoize: true) { Cogger.new formatter: :emoji }
|
29
|
+
register :kernel, Kernel
|
27
30
|
end
|
28
31
|
<% 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: 20.
|
4
|
+
version: 20.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brooke Kuhlmann
|
@@ -35,7 +35,7 @@ cert_chain:
|
|
35
35
|
3n5C8/6Zh9DYTkpcwPSuIfAga6wf4nXc9m6JAw8AuMLaiWN/r/2s4zJsUHYERJEu
|
36
36
|
gZGm4JqtuSg8pYjPeIJxS960owq+SfuC+jxqmRA54BisFCv/0VOJi7tiJVY=
|
37
37
|
-----END CERTIFICATE-----
|
38
|
-
date: 2023-
|
38
|
+
date: 2023-07-29 00:00:00.000000000 Z
|
39
39
|
dependencies:
|
40
40
|
- !ruby/object:Gem::Dependency
|
41
41
|
name: cogger
|
@@ -169,14 +169,14 @@ dependencies:
|
|
169
169
|
requirements:
|
170
170
|
- - "~>"
|
171
171
|
- !ruby/object:Gem::Version
|
172
|
-
version: '5.
|
172
|
+
version: '5.5'
|
173
173
|
type: :runtime
|
174
174
|
prerelease: false
|
175
175
|
version_requirements: !ruby/object:Gem::Requirement
|
176
176
|
requirements:
|
177
177
|
- - "~>"
|
178
178
|
- !ruby/object:Gem::Version
|
179
|
-
version: '5.
|
179
|
+
version: '5.5'
|
180
180
|
- !ruby/object:Gem::Dependency
|
181
181
|
name: runcom
|
182
182
|
requirement: !ruby/object:Gem::Requirement
|
@@ -325,7 +325,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
325
325
|
- !ruby/object:Gem::Version
|
326
326
|
version: '0'
|
327
327
|
requirements: []
|
328
|
-
rubygems_version: 3.4.
|
328
|
+
rubygems_version: 3.4.17
|
329
329
|
signing_key:
|
330
330
|
specification_version: 4
|
331
331
|
summary: A command line interface for smithing Ruby gems.
|
metadata.gz.sig
CHANGED
Binary file
|