Sha256: 9e3f9d3586303e69b0e1e23844974b01fe8b092dda4e4a80e9b75c1f2dc4de34
Contents?: true
Size: 713 Bytes
Versions: 3
Compression:
Stored size: 713 Bytes
Contents
# frozen_string_literal: true require 'stringio' require_relative 'base' require_relative '../options/common' module RubyTerraform module Commands class Output < Base include RubyTerraform::Options::Common def stdout @stdout.respond_to?(:string) ? @stdout : (@stdout = StringIO.new) end def subcommands %w[output] end def options %w[ -json -raw -no-color -state ] + super end def arguments(parameters) [parameters[:name]] end def do_after(parameters) result = stdout.string parameters[:name] ? result.chomp : result end end end end
Version data entries
3 entries across 3 versions & 1 rubygems