Sha256: 88ac7b3359c9e73daf553d07be3c09777f7b0e04b6b3edd7b0da353347e6121b

Contents?: true

Size: 422 Bytes

Versions: 27

Compression:

Stored size: 422 Bytes

Contents

# frozen_string_literal: true

require "json"

module Mihari
  module Emitters
    class StandardOutput < Base
      def valid?
        true
      end

      def emit(title:, description:, artifacts:, tags:)
        h = {
          title: title,
          description: description,
          artifacts: artifacts.map(&:data),
          tags: tags
        }
        puts JSON.pretty_generate(h)
      end
    end
  end
end

Version data entries

27 entries across 27 versions & 1 rubygems

Version Path
mihari-0.17.5 lib/mihari/emitters/stdout.rb
mihari-0.17.4 lib/mihari/emitters/stdout.rb
mihari-0.17.3 lib/mihari/emitters/stdout.rb
mihari-0.17.2 lib/mihari/emitters/stdout.rb
mihari-0.17.1 lib/mihari/emitters/stdout.rb
mihari-0.17.0 lib/mihari/emitters/stdout.rb
mihari-0.16.0 lib/mihari/emitters/stdout.rb
mihari-0.15.0 lib/mihari/emitters/stdout.rb
mihari-0.14.0 lib/mihari/emitters/stdout.rb
mihari-0.13.2 lib/mihari/emitters/stdout.rb
mihari-0.13.1 lib/mihari/emitters/stdout.rb
mihari-0.13.0 lib/mihari/emitters/stdout.rb
mihari-0.12.0 lib/mihari/emitters/stdout.rb
mihari-0.11.0 lib/mihari/emitters/stdout.rb
mihari-0.10.0 lib/mihari/emitters/stdout.rb
mihari-0.9.1 lib/mihari/emitters/stdout.rb
mihari-0.9.0 lib/mihari/emitters/stdout.rb
mihari-0.8.2 lib/mihari/emitters/stdout.rb
mihari-0.8.1 lib/mihari/emitters/stdout.rb
mihari-0.8.0 lib/mihari/emitters/stdout.rb