Sha256: 974994e8086daf79ac7185e120ebc1fc70fcc104c86ccb7e9d5c78d67dca9386

Contents?: true

Size: 623 Bytes

Versions: 6

Compression:

Stored size: 623 Bytes

Contents

module Lono::Cfn
  class Show < Base
    include Plan::Concerns

    def run
      logger.info "Info for stack: #{@stack.color(:green)}"
      logger.info "Resources:".color(:green)
      print
      Output.new(@options).run
    end

    def print
      summary.print(resource_types)
    end

    def resource_types
      resources = find_stack_resources(@stack)
      unless resources
        logger.info "ERROR: Stack #{@stack} not found".color(:red)
        exit 1
      end

      types = Hash.new(0)
      resources.each do |resource|
        types[resource.resource_type] += 1
      end
      types
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
lono-8.0.0.pre.rc6 lib/lono/cfn/show.rb
lono-8.0.0.pre.rc5 lib/lono/cfn/show.rb
lono-8.0.0.pre.rc4 lib/lono/cfn/show.rb
lono-8.0.0.pre.rc3 lib/lono/cfn/show.rb
lono-8.0.0.pre.rc2 lib/lono/cfn/show.rb
lono-8.0.0.pre.rc1 lib/lono/cfn/show.rb