Sha256: 7559cbb4daae6d6c4256df34e788114724b1142962502e474140782d41345e2d

Contents?: true

Size: 350 Bytes

Versions: 9

Compression:

Stored size: 350 Bytes

Contents

require "shopify_cli"

module ShopifyCli
  module Tasks
    class EnsureProjectType < ShopifyCli::Task
      def call(ctx, project_type)
        return true if project_type.to_sym == ShopifyCli::Project.current_project_type
        ctx.abort(ctx.message("core.tasks.ensure_project_type.wrong_project_type", project_type))
      end
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
shopify-cli-2.4.0 lib/shopify-cli/tasks/ensure_project_type.rb
shopify-cli-2.3.0 lib/shopify-cli/tasks/ensure_project_type.rb
shopify-cli-2.2.2 lib/shopify-cli/tasks/ensure_project_type.rb
shopify-cli-2.2.1 lib/shopify-cli/tasks/ensure_project_type.rb
shopify-cli-2.2.0 lib/shopify-cli/tasks/ensure_project_type.rb
shopify-cli-2.1.0 lib/shopify-cli/tasks/ensure_project_type.rb
shopify-cli-2.0.2 lib/shopify-cli/tasks/ensure_project_type.rb
shopify-cli-2.0.1 lib/shopify-cli/tasks/ensure_project_type.rb
shopify-cli-2.0.0 lib/shopify-cli/tasks/ensure_project_type.rb