Sha256: 345e0c1ceb47fb98cd65dd636e76f57a8afccc8be202db81a5b88319d45f8a02

Contents?: true

Size: 414 Bytes

Versions: 3

Compression:

Stored size: 414 Bytes

Contents

# frozen_string_literal: true

module Codeowners
  module Cli
    # Provides convenience methods like :ask, :yes? without subclassing Thor
    module InteractiveOps
      def yes?(statement, color = nil)
        thor.yes?(statement, color)
      end

      def ask(statement, *args)
        thor.ask(statement, *args)
      end

      private

      def thor
        @thor ||= Thor.new
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
codeowners-checker-1.1.2 lib/codeowners/cli/interactive_ops.rb
codeowners-checker-1.1.1 lib/codeowners/cli/interactive_ops.rb
codeowners-checker-1.0.5 lib/codeowners/cli/interactive_ops.rb