Sha256: c71d62c7dff75b28c8d092cf4cf96e25015c743b0e2ccf8aa6d8b77db154d143

Contents?: true

Size: 700 Bytes

Versions: 9

Compression:

Stored size: 700 Bytes

Contents

# frozen_string_literal: true

module Script
  module Layers
    module Infrastructure
      class ProjectCreator
        PROJECT_CREATORS = {
          "assemblyscript" => Infrastructure::AssemblyScriptProjectCreator,
          "rust" => Infrastructure::RustProjectCreator,
        }

        def self.for(ctx, language, extension_point, script_name, path_to_project)
          raise Errors::ProjectCreatorNotFoundError unless PROJECT_CREATORS[language]
          PROJECT_CREATORS[language].new(
            ctx: ctx,
            extension_point: extension_point,
            script_name: script_name,
            path_to_project: path_to_project
          )
        end
      end
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
shopify-cli-1.12.0 lib/project_types/script/layers/infrastructure/project_creator.rb
shopify-cli-1.11.0 lib/project_types/script/layers/infrastructure/project_creator.rb
shopify-cli-1.10.0 lib/project_types/script/layers/infrastructure/project_creator.rb
shopify-cli-1.9.1 lib/project_types/script/layers/infrastructure/project_creator.rb
shopify-cli-1.9.0 lib/project_types/script/layers/infrastructure/project_creator.rb
shopify-cli-1.8.0 lib/project_types/script/layers/infrastructure/project_creator.rb
shopify-cli-1.7.1 lib/project_types/script/layers/infrastructure/project_creator.rb
shopify-cli-1.7.0 lib/project_types/script/layers/infrastructure/project_creator.rb
shopify-cli-1.6.0 lib/project_types/script/layers/infrastructure/project_creator.rb