Class: Rubysmith::Builders::Documentation::License
- Inherits:
-
Object
- Object
- Rubysmith::Builders::Documentation::License
- Defined in:
- lib/rubysmith/builders/documentation/license.rb
Overview
Builds project skeleton LICENSE documentation.
Class Method Summary collapse
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(configuration, builder: Builder) ⇒ License
constructor
A new instance of License.
Constructor Details
Class Method Details
.call ⇒ Object
13 |
# File 'lib/rubysmith/builders/documentation/license.rb', line 13 def self.call(...) = new(...).call |
Instance Method Details
#call ⇒ Object
20 21 22 23 24 25 26 27 28 29 |
# File 'lib/rubysmith/builders/documentation/license.rb', line 20 def call return configuration unless configuration.build_license configuration.merge(template_path: "%project_name%/LICENSE-#{license}.#{kind}.erb") .then do |updated_configuration| builder.call(updated_configuration).render.rename "LICENSE.#{kind}" end configuration end |