Sha256: 66c3c8a9ae08c0483ce94c12e4a154b0f201cf5063b61021d13cde52db4839e3
Contents?: true
Size: 968 Bytes
Versions: 22
Compression:
Stored size: 968 Bytes
Contents
module Buildkite module Builder class Group include Buildkite::Pipelines::Attributes attr_reader :label attr_reader :data attribute :depends_on, append: true attribute :key def self.to_sym name.split('::').last.downcase.to_sym end def initialize(label, steps, &block) @label = label @data = Data.new @data.steps = StepCollection.new( steps.templates, steps.plugins ) @data.notify = [] @dsl = Dsl.new(self) @dsl.extend(Extensions::Steps) @dsl.extend(Extensions::Notify) instance_eval(&block) if block_given? self end def to_h attributes = super { group: label }.merge(attributes).merge(data.to_definition) end def method_missing(method_name, *args, **kwargs, &_block) @dsl.public_send(method_name, *args, **kwargs, &_block) end end end end
Version data entries
22 entries across 22 versions & 1 rubygems