Sha256: 6ea668e10858095aeaa51913e40492171edf66f9aeb4b2c124f59bc1f5b205a6
Contents?: true
Size: 709 Bytes
Versions: 8
Compression:
Stored size: 709 Bytes
Contents
# frozen_string_literal: true require "refinements/struct" module Rubysmith module Builders module Git # Initializes project skeleton with Git Safe support. class Safe using Refinements::Struct def self.call(...) = new(...).call def initialize configuration, builder: Builder @configuration = configuration @builder = builder end def call return configuration unless configuration.build_git builder.call(configuration.merge(template_path: "%project_name%/.git/safe")).make_path configuration end private attr_reader :configuration, :builder end end end end
Version data entries
8 entries across 8 versions & 1 rubygems