Sha256: f18255f73a0c49e4b9f344f920e6dda2ac6f32a7f4a96436fac80d68d42dac5a

Contents?: true

Size: 1.21 KB

Versions: 7

Compression:

Stored size: 1.21 KB

Contents

# frozen_string_literal: true

module Rubysmith
  module CLI
    module Actions
      # Handles the build action.
      class Build
        # Order is important.
        BUILDERS = [
          Builders::Core,
          Builders::Version,
          Builders::Documentation::Readme,
          Builders::Documentation::Citation,
          Builders::Documentation::License,
          Builders::Documentation::Version,
          Builders::Git::Setup,
          Builders::Git::Ignore,
          Builders::Bundler,
          Builders::Rake,
          Builders::Console,
          Builders::CircleCI,
          Builders::Setup,
          Builders::GitHub,
          Builders::Guard,
          Builders::Reek,
          Builders::RSpec::Context,
          Builders::RSpec::Helper,
          Builders::Caliber,
          Extensions::Bundler,
          Extensions::Pragmater,
          Extensions::Tocer,
          Extensions::Rubocop,
          Builders::Git::Commit
        ].freeze

        def initialize builders: BUILDERS
          @builders = builders
        end

        def call(configuration) = builders.each { |builder| builder.call configuration }

        private

        attr_reader :configuration, :builders
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
rubysmith-3.2.0 lib/rubysmith/cli/actions/build.rb
rubysmith-3.1.0 lib/rubysmith/cli/actions/build.rb
rubysmith-3.0.1 lib/rubysmith/cli/actions/build.rb
rubysmith-3.0.0 lib/rubysmith/cli/actions/build.rb
rubysmith-2.0.2 lib/rubysmith/cli/actions/build.rb
rubysmith-2.0.1 lib/rubysmith/cli/actions/build.rb
rubysmith-2.0.0 lib/rubysmith/cli/actions/build.rb