rubysmith 0.9.1 → 0.13.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 +4 -4
- checksums.yaml.gz.sig +0 -0
- data/README.adoc +34 -20
- data/bin/rubysmith +0 -1
- data/lib/rubysmith/builder.rb +17 -35
- data/lib/rubysmith/builders/bundler.rb +7 -9
- data/lib/rubysmith/builders/console.rb +6 -8
- data/lib/rubysmith/builders/core.rb +11 -8
- data/lib/rubysmith/builders/documentation.rb +16 -21
- data/lib/rubysmith/builders/git/commit.rb +7 -11
- data/lib/rubysmith/builders/git/setup.rb +6 -8
- data/lib/rubysmith/builders/guard.rb +9 -9
- data/lib/rubysmith/builders/pragma.rb +8 -13
- data/lib/rubysmith/builders/rake.rb +7 -7
- data/lib/rubysmith/builders/reek.rb +6 -8
- data/lib/rubysmith/builders/rspec/context.rb +10 -11
- data/lib/rubysmith/builders/rspec/helper.rb +6 -8
- data/lib/rubysmith/builders/rubocop/formatter.rb +5 -7
- data/lib/rubysmith/builders/rubocop/setup.rb +7 -9
- data/lib/rubysmith/builders/setup.rb +8 -8
- data/lib/rubysmith/cli/actions/build.rb +42 -0
- data/lib/rubysmith/cli/actions/config.rb +33 -0
- data/lib/rubysmith/cli/configuration/content.rb +78 -0
- data/lib/rubysmith/cli/{defaults.yml → configuration/defaults.yml} +3 -3
- data/lib/rubysmith/cli/configuration/loader.rb +38 -0
- data/lib/rubysmith/cli/parsers/assembler.rb +11 -18
- data/lib/rubysmith/cli/parsers/build.rb +40 -41
- data/lib/rubysmith/cli/parsers/core.rb +15 -14
- data/lib/rubysmith/cli/parsers.rb +11 -0
- data/lib/rubysmith/cli/shell.rb +14 -35
- data/lib/rubysmith/container.rb +37 -0
- data/lib/rubysmith/identity.rb +2 -2
- data/lib/rubysmith/pathway.rb +3 -9
- data/lib/rubysmith/renderers/erb.rb +7 -9
- data/lib/rubysmith/renderers/namespace.rb +2 -4
- data/lib/rubysmith/templates/%project_name%/.rubocop.yml.erb +1 -1
- data/lib/rubysmith/templates/%project_name%/CHANGES.adoc.erb +1 -1
- data/lib/rubysmith/templates/%project_name%/CHANGES.md.erb +1 -1
- data/lib/rubysmith/templates/%project_name%/CODE_OF_CONDUCT.adoc.erb +2 -2
- data/lib/rubysmith/templates/%project_name%/CODE_OF_CONDUCT.md.erb +1 -1
- data/lib/rubysmith/templates/%project_name%/Gemfile.erb +46 -50
- data/lib/rubysmith/templates/%project_name%/LICENSE-apache.adoc.erb +1 -1
- data/lib/rubysmith/templates/%project_name%/LICENSE-apache.md.erb +1 -1
- data/lib/rubysmith/templates/%project_name%/LICENSE-mit.adoc.erb +1 -1
- data/lib/rubysmith/templates/%project_name%/LICENSE-mit.md.erb +1 -1
- data/lib/rubysmith/templates/%project_name%/README.adoc.erb +5 -5
- data/lib/rubysmith/templates/%project_name%/README.md.erb +5 -5
- data/lib/rubysmith/templates/%project_name%/Rakefile.erb +11 -23
- data/lib/rubysmith/templates/%project_name%/bin/console.erb +1 -1
- data/lib/rubysmith/templates/%project_name%/lib/%project_path%.rb.erb +12 -0
- data/lib/rubysmith/templates/%project_name%/spec/spec_helper.rb.erb +6 -4
- data/lib/rubysmith/templates/%project_name%/spec/support/shared_contexts/temp_dir.rb.erb +3 -3
- data/lib/rubysmith.rb +10 -30
- data.tar.gz.sig +0 -0
- metadata +55 -13
- metadata.gz.sig +0 -0
- data/lib/rubysmith/builders/ruby_critic.rb +0 -27
- data/lib/rubysmith/cli/configuration.rb +0 -30
- data/lib/rubysmith/cli/processors/build.rb +0 -58
- data/lib/rubysmith/cli/processors/config.rb +0 -35
- data/lib/rubysmith/realm.rb +0 -74
- data/lib/rubysmith/templates/%project_name%/.rubycritic.yml.erb +0 -3
- data/lib/rubysmith/templates/%project_name%/lib/%project_name%.rb.erb +0 -3
@@ -0,0 +1,12 @@
|
|
1
|
+
<% if configuration.build_zeitwerk %>
|
2
|
+
require "zeitwerk"
|
3
|
+
<% if configuration.project_path.include? "/" %>
|
4
|
+
Zeitwerk::Loader.new
|
5
|
+
.tap { |loader| loader.push_dir "#{__dir__}/.." }
|
6
|
+
.setup
|
7
|
+
<% else %>
|
8
|
+
Zeitwerk::Loader.for_gem.setup
|
9
|
+
<% end %>
|
10
|
+
<% end %>
|
11
|
+
# Main namespace.
|
12
|
+
<% namespace %>
|
@@ -1,18 +1,20 @@
|
|
1
1
|
require "bundler/setup"
|
2
2
|
Bundler.require :tools
|
3
3
|
|
4
|
-
<% if
|
4
|
+
<% if configuration.build_simple_cov %>
|
5
5
|
require "simplecov"
|
6
6
|
SimpleCov.start { enable_coverage :branch }
|
7
7
|
<% end %>
|
8
8
|
|
9
|
-
require "<%=
|
10
|
-
<% if
|
9
|
+
require "<%= configuration.project_path %>"
|
10
|
+
<% if configuration.build_refinements %>
|
11
|
+
require "refinements"
|
12
|
+
<% end %>
|
11
13
|
|
12
14
|
GC.auto_compact = true
|
13
15
|
GC.verify_compaction_references double_heap: true, toward: :empty
|
14
16
|
|
15
|
-
<% if
|
17
|
+
<% if configuration.build_refinements %>
|
16
18
|
using Refinements::Pathnames
|
17
19
|
|
18
20
|
Pathname.require_tree __dir__, "support/shared_contexts/**/*.rb"
|
@@ -1,11 +1,11 @@
|
|
1
1
|
RSpec.shared_context "with temporary directory" do
|
2
|
-
<% if
|
2
|
+
<% if configuration.build_refinements %>using Refinements::Pathnames<% end %>
|
3
3
|
|
4
4
|
let(:temp_dir) { Bundler.root.join "tmp/rspec" }
|
5
5
|
|
6
6
|
around do |example|
|
7
|
-
<%=
|
7
|
+
<%= configuration.build_refinements ? "temp_dir.make_path" : "FileUtils.mkdir_p temp_dir" %>
|
8
8
|
example.run
|
9
|
-
<%=
|
9
|
+
<%= configuration.build_refinements ? "temp_dir.remove_tree" : "FileUtils.rm_rf temp_dir" %>
|
10
10
|
end
|
11
11
|
end
|
data/lib/rubysmith.rb
CHANGED
@@ -1,32 +1,12 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
require "
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
require "rubysmith/builders/git/commit"
|
14
|
-
require "rubysmith/builders/bundler"
|
15
|
-
require "rubysmith/builders/rake"
|
16
|
-
require "rubysmith/builders/console"
|
17
|
-
require "rubysmith/builders/setup"
|
18
|
-
require "rubysmith/builders/guard"
|
19
|
-
require "rubysmith/builders/reek"
|
20
|
-
require "rubysmith/builders/rspec/context"
|
21
|
-
require "rubysmith/builders/rspec/helper"
|
22
|
-
require "rubysmith/builders/pragma"
|
23
|
-
require "rubysmith/builders/rubocop/setup"
|
24
|
-
require "rubysmith/builders/rubocop/formatter"
|
25
|
-
require "rubysmith/builders/ruby_critic"
|
26
|
-
require "rubysmith/cli/parsers/core"
|
27
|
-
require "rubysmith/cli/parsers/build"
|
28
|
-
require "rubysmith/cli/parsers/assembler"
|
29
|
-
require "rubysmith/cli/processors/config"
|
30
|
-
require "rubysmith/cli/processors/build"
|
31
|
-
require "rubysmith/cli/configuration"
|
32
|
-
require "rubysmith/cli/shell"
|
3
|
+
require "zeitwerk"
|
4
|
+
|
5
|
+
Zeitwerk::Loader.for_gem.then do |loader|
|
6
|
+
loader.inflector.inflect "cli" => "CLI", "erb" => "ERB", "rspec" => "RSpec"
|
7
|
+
loader.setup
|
8
|
+
end
|
9
|
+
|
10
|
+
# Main namespace.
|
11
|
+
module Rubysmith
|
12
|
+
end
|
data.tar.gz.sig
CHANGED
Binary file
|
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.
|
4
|
+
version: 0.13.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brooke Kuhlmann
|
@@ -28,8 +28,36 @@ cert_chain:
|
|
28
28
|
lkHilIrX69jq8wMPpBhlaw2mRmeSL50Wv5u6xVBvOHhXFSP1crXM95vfLhLyRYod
|
29
29
|
W2A=
|
30
30
|
-----END CERTIFICATE-----
|
31
|
-
date: 2021-
|
31
|
+
date: 2021-09-16 00:00:00.000000000 Z
|
32
32
|
dependencies:
|
33
|
+
- !ruby/object:Gem::Dependency
|
34
|
+
name: dry-container
|
35
|
+
requirement: !ruby/object:Gem::Requirement
|
36
|
+
requirements:
|
37
|
+
- - "~>"
|
38
|
+
- !ruby/object:Gem::Version
|
39
|
+
version: '0.9'
|
40
|
+
type: :runtime
|
41
|
+
prerelease: false
|
42
|
+
version_requirements: !ruby/object:Gem::Requirement
|
43
|
+
requirements:
|
44
|
+
- - "~>"
|
45
|
+
- !ruby/object:Gem::Version
|
46
|
+
version: '0.9'
|
47
|
+
- !ruby/object:Gem::Dependency
|
48
|
+
name: pastel
|
49
|
+
requirement: !ruby/object:Gem::Requirement
|
50
|
+
requirements:
|
51
|
+
- - "~>"
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: '0.8'
|
54
|
+
type: :runtime
|
55
|
+
prerelease: false
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
requirements:
|
58
|
+
- - "~>"
|
59
|
+
- !ruby/object:Gem::Version
|
60
|
+
version: '0.8'
|
33
61
|
- !ruby/object:Gem::Dependency
|
34
62
|
name: pragmater
|
35
63
|
requirement: !ruby/object:Gem::Requirement
|
@@ -64,14 +92,14 @@ dependencies:
|
|
64
92
|
requirements:
|
65
93
|
- - "~>"
|
66
94
|
- !ruby/object:Gem::Version
|
67
|
-
version: '1.
|
95
|
+
version: '1.20'
|
68
96
|
type: :runtime
|
69
97
|
prerelease: false
|
70
98
|
version_requirements: !ruby/object:Gem::Requirement
|
71
99
|
requirements:
|
72
100
|
- - "~>"
|
73
101
|
- !ruby/object:Gem::Version
|
74
|
-
version: '1.
|
102
|
+
version: '1.20'
|
75
103
|
- !ruby/object:Gem::Dependency
|
76
104
|
name: runcom
|
77
105
|
requirement: !ruby/object:Gem::Requirement
|
@@ -86,6 +114,20 @@ dependencies:
|
|
86
114
|
- - "~>"
|
87
115
|
- !ruby/object:Gem::Version
|
88
116
|
version: '7.0'
|
117
|
+
- !ruby/object:Gem::Dependency
|
118
|
+
name: zeitwerk
|
119
|
+
requirement: !ruby/object:Gem::Requirement
|
120
|
+
requirements:
|
121
|
+
- - "~>"
|
122
|
+
- !ruby/object:Gem::Version
|
123
|
+
version: '2.4'
|
124
|
+
type: :runtime
|
125
|
+
prerelease: false
|
126
|
+
version_requirements: !ruby/object:Gem::Requirement
|
127
|
+
requirements:
|
128
|
+
- - "~>"
|
129
|
+
- !ruby/object:Gem::Version
|
130
|
+
version: '2.4'
|
89
131
|
description:
|
90
132
|
email:
|
91
133
|
- brooke@alchemists.io
|
@@ -115,25 +157,25 @@ files:
|
|
115
157
|
- lib/rubysmith/builders/rspec/helper.rb
|
116
158
|
- lib/rubysmith/builders/rubocop/formatter.rb
|
117
159
|
- lib/rubysmith/builders/rubocop/setup.rb
|
118
|
-
- lib/rubysmith/builders/ruby_critic.rb
|
119
160
|
- lib/rubysmith/builders/setup.rb
|
120
|
-
- lib/rubysmith/cli/
|
121
|
-
- lib/rubysmith/cli/
|
161
|
+
- lib/rubysmith/cli/actions/build.rb
|
162
|
+
- lib/rubysmith/cli/actions/config.rb
|
163
|
+
- lib/rubysmith/cli/configuration/content.rb
|
164
|
+
- lib/rubysmith/cli/configuration/defaults.yml
|
165
|
+
- lib/rubysmith/cli/configuration/loader.rb
|
166
|
+
- lib/rubysmith/cli/parsers.rb
|
122
167
|
- lib/rubysmith/cli/parsers/assembler.rb
|
123
168
|
- lib/rubysmith/cli/parsers/build.rb
|
124
169
|
- lib/rubysmith/cli/parsers/core.rb
|
125
|
-
- lib/rubysmith/cli/processors/build.rb
|
126
|
-
- lib/rubysmith/cli/processors/config.rb
|
127
170
|
- lib/rubysmith/cli/shell.rb
|
171
|
+
- lib/rubysmith/container.rb
|
128
172
|
- lib/rubysmith/identity.rb
|
129
173
|
- lib/rubysmith/pathway.rb
|
130
|
-
- lib/rubysmith/realm.rb
|
131
174
|
- lib/rubysmith/renderers/erb.rb
|
132
175
|
- lib/rubysmith/renderers/namespace.rb
|
133
176
|
- lib/rubysmith/templates/%project_name%/.reek.yml.erb
|
134
177
|
- lib/rubysmith/templates/%project_name%/.rubocop.yml.erb
|
135
178
|
- lib/rubysmith/templates/%project_name%/.ruby-version.erb
|
136
|
-
- lib/rubysmith/templates/%project_name%/.rubycritic.yml.erb
|
137
179
|
- lib/rubysmith/templates/%project_name%/CHANGES.adoc.erb
|
138
180
|
- lib/rubysmith/templates/%project_name%/CHANGES.md.erb
|
139
181
|
- lib/rubysmith/templates/%project_name%/CODE_OF_CONDUCT.adoc.erb
|
@@ -153,7 +195,7 @@ files:
|
|
153
195
|
- lib/rubysmith/templates/%project_name%/bin/guard.erb
|
154
196
|
- lib/rubysmith/templates/%project_name%/bin/rubocop.erb
|
155
197
|
- lib/rubysmith/templates/%project_name%/bin/setup.erb
|
156
|
-
- lib/rubysmith/templates/%project_name%/lib/%
|
198
|
+
- lib/rubysmith/templates/%project_name%/lib/%project_path%.rb.erb
|
157
199
|
- lib/rubysmith/templates/%project_name%/spec/spec_helper.rb.erb
|
158
200
|
- lib/rubysmith/templates/%project_name%/spec/support/shared_contexts/temp_dir.rb.erb
|
159
201
|
- lib/rubysmith/text/inserter.rb
|
@@ -180,7 +222,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
180
222
|
- !ruby/object:Gem::Version
|
181
223
|
version: '0'
|
182
224
|
requirements: []
|
183
|
-
rubygems_version: 3.2.
|
225
|
+
rubygems_version: 3.2.27
|
184
226
|
signing_key:
|
185
227
|
specification_version: 4
|
186
228
|
summary: A command line interface for smithing Ruby projects.
|
metadata.gz.sig
CHANGED
Binary file
|
@@ -1,27 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
module Rubysmith
|
4
|
-
module Builders
|
5
|
-
# Builds project skeleton RubyCritic code quality support.
|
6
|
-
class RubyCritic
|
7
|
-
def self.call realm, builder: Builder
|
8
|
-
new(realm, builder: builder).call
|
9
|
-
end
|
10
|
-
|
11
|
-
def initialize realm, builder: Builder
|
12
|
-
@realm = realm
|
13
|
-
@builder = builder
|
14
|
-
end
|
15
|
-
|
16
|
-
def call
|
17
|
-
return unless realm.build_ruby_critic
|
18
|
-
|
19
|
-
builder.call(realm.with(template_path: "%project_name%/.rubycritic.yml.erb")).render
|
20
|
-
end
|
21
|
-
|
22
|
-
private
|
23
|
-
|
24
|
-
attr_reader :realm, :builder
|
25
|
-
end
|
26
|
-
end
|
27
|
-
end
|
@@ -1,30 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
require "pathname"
|
4
|
-
require "refinements/hashes"
|
5
|
-
require "runcom"
|
6
|
-
require "yaml"
|
7
|
-
|
8
|
-
module Rubysmith
|
9
|
-
module CLI
|
10
|
-
# Represents the fully assembled Command Line Interface (CLI) configuration.
|
11
|
-
class Configuration
|
12
|
-
using Refinements::Hashes
|
13
|
-
|
14
|
-
DEFAULTS = YAML.load_file(Pathname(__dir__).join("defaults.yml")).freeze
|
15
|
-
CLIENT = Runcom::Config.new "#{Identity::NAME}/configuration.yml", defaults: DEFAULTS
|
16
|
-
|
17
|
-
def initialize client: CLIENT
|
18
|
-
@client = client
|
19
|
-
end
|
20
|
-
|
21
|
-
def to_h
|
22
|
-
client.to_h.flatten_keys
|
23
|
-
end
|
24
|
-
|
25
|
-
private
|
26
|
-
|
27
|
-
attr_reader :client
|
28
|
-
end
|
29
|
-
end
|
30
|
-
end
|
@@ -1,58 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
module Rubysmith
|
4
|
-
module CLI
|
5
|
-
module Processors
|
6
|
-
# Handles the Command Line Interface (CLI) for building of a project skeleton.
|
7
|
-
class Build
|
8
|
-
# Order is important.
|
9
|
-
MINIMUM = [
|
10
|
-
Builders::Core,
|
11
|
-
Builders::Bundler,
|
12
|
-
Builders::Pragma,
|
13
|
-
Builders::Rubocop::Formatter
|
14
|
-
].freeze
|
15
|
-
|
16
|
-
# Order is important.
|
17
|
-
MAXIMUM = [
|
18
|
-
Builders::Core,
|
19
|
-
Builders::Documentation,
|
20
|
-
Builders::Git::Setup,
|
21
|
-
Builders::Bundler,
|
22
|
-
Builders::Rake,
|
23
|
-
Builders::Console,
|
24
|
-
Builders::Setup,
|
25
|
-
Builders::Guard,
|
26
|
-
Builders::Reek,
|
27
|
-
Builders::RSpec::Context,
|
28
|
-
Builders::RSpec::Helper,
|
29
|
-
Builders::Pragma,
|
30
|
-
Builders::Rubocop::Setup,
|
31
|
-
Builders::Rubocop::Formatter,
|
32
|
-
Builders::RubyCritic,
|
33
|
-
Builders::Git::Commit
|
34
|
-
].freeze
|
35
|
-
|
36
|
-
def self.with_minimum
|
37
|
-
new builders: MINIMUM
|
38
|
-
end
|
39
|
-
|
40
|
-
def initialize builders: MAXIMUM
|
41
|
-
@builders = builders
|
42
|
-
end
|
43
|
-
|
44
|
-
def call options
|
45
|
-
Realm[**options].then { |realm| process realm }
|
46
|
-
end
|
47
|
-
|
48
|
-
private
|
49
|
-
|
50
|
-
attr_reader :builders
|
51
|
-
|
52
|
-
def process realm
|
53
|
-
builders.each { |builder| builder.call realm }
|
54
|
-
end
|
55
|
-
end
|
56
|
-
end
|
57
|
-
end
|
58
|
-
end
|
@@ -1,35 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
module Rubysmith
|
4
|
-
module CLI
|
5
|
-
module Processors
|
6
|
-
# Handles the Command Line Interface (CLI) configuration processing.
|
7
|
-
class Config
|
8
|
-
def initialize configuration: CLI::Configuration::CLIENT, kernel: Kernel
|
9
|
-
@configuration = configuration
|
10
|
-
@kernel = kernel
|
11
|
-
end
|
12
|
-
|
13
|
-
def call action
|
14
|
-
case action
|
15
|
-
when :edit then edit
|
16
|
-
when :view then view
|
17
|
-
else fail StandardError, "Invalid configuration action: #{action}."
|
18
|
-
end
|
19
|
-
end
|
20
|
-
|
21
|
-
private
|
22
|
-
|
23
|
-
attr_reader :configuration, :kernel
|
24
|
-
|
25
|
-
def edit
|
26
|
-
kernel.system "$EDITOR #{configuration.current}"
|
27
|
-
end
|
28
|
-
|
29
|
-
def view
|
30
|
-
kernel.system "cat #{configuration.current}"
|
31
|
-
end
|
32
|
-
end
|
33
|
-
end
|
34
|
-
end
|
35
|
-
end
|
data/lib/rubysmith/realm.rb
DELETED
@@ -1,74 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
require "pathname"
|
4
|
-
require "refinements/strings"
|
5
|
-
|
6
|
-
module Rubysmith
|
7
|
-
REALM_KEYS = %i[
|
8
|
-
config
|
9
|
-
template_root
|
10
|
-
template_path
|
11
|
-
build_root
|
12
|
-
project_name
|
13
|
-
author_name
|
14
|
-
author_email
|
15
|
-
author_url
|
16
|
-
now
|
17
|
-
documentation_format
|
18
|
-
documentation_license
|
19
|
-
build_minimum
|
20
|
-
build_amazing_print
|
21
|
-
build_bundler_audit
|
22
|
-
build_bundler_leak
|
23
|
-
build_console
|
24
|
-
build_documentation
|
25
|
-
build_git
|
26
|
-
build_git_lint
|
27
|
-
build_guard
|
28
|
-
build_pry
|
29
|
-
build_reek
|
30
|
-
build_refinements
|
31
|
-
build_rspec
|
32
|
-
build_rubocop
|
33
|
-
build_ruby_critic
|
34
|
-
build_setup
|
35
|
-
build_simple_cov
|
36
|
-
builders_pragmater_comments
|
37
|
-
builders_pragmater_includes
|
38
|
-
version
|
39
|
-
help
|
40
|
-
].freeze
|
41
|
-
|
42
|
-
# Represents the common context in which all builders and templates operate in.
|
43
|
-
Realm = Struct.new(*REALM_KEYS, keyword_init: true) do
|
44
|
-
using Refinements::Strings
|
45
|
-
|
46
|
-
def initialize *arguments
|
47
|
-
super
|
48
|
-
|
49
|
-
self[:template_root] ||= Pathname(__dir__).join("templates").expand_path
|
50
|
-
self[:build_root] ||= Pathname.pwd
|
51
|
-
freeze
|
52
|
-
end
|
53
|
-
|
54
|
-
def with attributes
|
55
|
-
self.class.new to_h.merge(attributes)
|
56
|
-
end
|
57
|
-
|
58
|
-
def project_label
|
59
|
-
project_name.titleize
|
60
|
-
end
|
61
|
-
|
62
|
-
def project_class
|
63
|
-
project_name.camelcase
|
64
|
-
end
|
65
|
-
|
66
|
-
def project_root
|
67
|
-
build_root.join project_name
|
68
|
-
end
|
69
|
-
|
70
|
-
def to_pathway
|
71
|
-
Pathway[start_root: template_root, start_path: template_path, end_root: build_root]
|
72
|
-
end
|
73
|
-
end
|
74
|
-
end
|