Sha256: 976ec613b78111d450151a9939668dcf8601462ca53452de0eba26240337e51b

Contents?: true

Size: 464 Bytes

Versions: 20

Compression:

Stored size: 464 Bytes

Contents

require "cli/kit"

module ShopifyCli
  module Core
    class HelpResolver < CLI::Kit::Resolver
      def call(args)
        args = args.dup
        return super(args) unless args.first
        if args.first.include?("-h") || args.first.include?("--help")
          help = Commands::Help
          help.ctx = Context.new
          help.call([], nil)
          raise ShopifyCli::AbortSilent
        else
          super(args)
        end
      end
    end
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
shopify-cli-2.4.0 lib/shopify-cli/core/help_resolver.rb
shopify-cli-2.3.0 lib/shopify-cli/core/help_resolver.rb
shopify-cli-2.2.2 lib/shopify-cli/core/help_resolver.rb
shopify-cli-2.2.1 lib/shopify-cli/core/help_resolver.rb
shopify-cli-2.2.0 lib/shopify-cli/core/help_resolver.rb
shopify-cli-2.1.0 lib/shopify-cli/core/help_resolver.rb
shopify-cli-2.0.2 lib/shopify-cli/core/help_resolver.rb
shopify-cli-2.0.1 lib/shopify-cli/core/help_resolver.rb
shopify-cli-2.0.0 lib/shopify-cli/core/help_resolver.rb
shopify-cli-1.14.0 lib/shopify-cli/core/help_resolver.rb
shopify-cli-1.13.1 lib/shopify-cli/core/help_resolver.rb
shopify-cli-1.13.0 lib/shopify-cli/core/help_resolver.rb
shopify-cli-1.12.0 lib/shopify-cli/core/help_resolver.rb
shopify-cli-1.11.0 lib/shopify-cli/core/help_resolver.rb
shopify-cli-1.10.0 lib/shopify-cli/core/help_resolver.rb
shopify-cli-1.9.1 lib/shopify-cli/core/help_resolver.rb
shopify-cli-1.9.0 lib/shopify-cli/core/help_resolver.rb
shopify-cli-1.8.0 lib/shopify-cli/core/help_resolver.rb
shopify-cli-1.7.1 lib/shopify-cli/core/help_resolver.rb
shopify-cli-1.7.0 lib/shopify-cli/core/help_resolver.rb