Sha256: 36a717876aea7374abd04f8bac7c7cfe8fa1867763c63e3148e360e865bd7ece
Contents?: true
Size: 635 Bytes
Versions: 51
Compression:
Stored size: 635 Bytes
Contents
# frozen_string_literal: true module Bolt class Outputter def self.for_format(format, color, verbose, trace) case format when 'human' Bolt::Outputter::Human.new(color, verbose, trace) when 'json' Bolt::Outputter::JSON.new(color, verbose, trace) when nil raise "Cannot use outputter before parsing." end end def initialize(color, verbose, trace, stream = $stdout) @color = color @verbose = verbose @trace = trace @stream = stream end end end require 'bolt/outputter/human' require 'bolt/outputter/json' require 'bolt/outputter/logger'
Version data entries
51 entries across 51 versions & 1 rubygems