Sha256: 4c0434d93e13f4762171656cd9435189de43129db4e99591fad9ef6a44a0c802

Contents?: true

Size: 591 Bytes

Versions: 10

Compression:

Stored size: 591 Bytes

Contents

# frozen_string_literal: true

require "refinements/struct"

module Rubysmith
  module Builders
    # Builds project skeleton with Caliber style support.
    class Caliber < Abstract
      using Refinements::Struct

      def call
        return false unless settings.build_caliber

        builder.call(settings.merge(template_path: "%project_name%/bin/rubocop.erb"))
               .render
               .permit 0o755

        path = "%project_name%/.config/rubocop/config.yml.erb"
        builder.call(settings.merge(template_path: path)).render
        true
      end
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
rubysmith-7.9.0 lib/rubysmith/builders/caliber.rb
rubysmith-7.8.0 lib/rubysmith/builders/caliber.rb
rubysmith-7.7.0 lib/rubysmith/builders/caliber.rb
rubysmith-7.6.0 lib/rubysmith/builders/caliber.rb
rubysmith-7.5.0 lib/rubysmith/builders/caliber.rb
rubysmith-7.4.0 lib/rubysmith/builders/caliber.rb
rubysmith-7.3.0 lib/rubysmith/builders/caliber.rb
rubysmith-7.2.0 lib/rubysmith/builders/caliber.rb
rubysmith-7.1.0 lib/rubysmith/builders/caliber.rb
rubysmith-7.0.0 lib/rubysmith/builders/caliber.rb