Sha256: 6778ebd7d33400c390764e136089558c0742d476bd692f75121558c61d74d68b

Contents?: true

Size: 798 Bytes

Versions: 7

Compression:

Stored size: 798 Bytes

Contents

require 'json'
require_relative 'step'
require_relative 'support/build_metadata'
require_relative 'support/params'
require_relative 'support/work_dir'

module Fuselage
  class Out < Step
    include Support::BuildMetadata
    include Support::Params
    include Support::WorkDir

    Contract None => HashOf[String, String]
    def version
      fail NotImplementedError
    end

    Contract None => ArrayOf[Maybe[HashOf[String, String]]]
    def metadata
      []
    end

    Contract None => String
    def output
      JSON.dump version: version, metadata: metadata
    end

    Contract None => Any
    def update!
      fail NotImplementedError
    end

    Contract None => String
    def run
      update!
      p output.tap { |string| STDERR.puts string if debugging? }
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
concourse-fuselage-0.5.0 lib/concourse-fuselage/out.rb
concourse-fuselage-0.4.1 lib/concourse-fuselage/out.rb
concourse-fuselage-0.4.0 lib/concourse-fuselage/out.rb
concourse-fuselage-0.3.2 lib/concourse-fuselage/out.rb
concourse-fuselage-0.3.1 lib/concourse-fuselage/out.rb
concourse-fuselage-0.3.0 lib/concourse-fuselage/out.rb
concourse-fuselage-0.2.0 lib/concourse-fuselage/out.rb