Class: Buildkite::Builder::Extensions::Plugins
- Inherits:
-
Buildkite::Builder::Extension
- Object
- Buildkite::Builder::Extension
- Buildkite::Builder::Extensions::Plugins
- Defined in:
- lib/buildkite/builder/extensions/plugins.rb
Instance Attribute Summary collapse
-
#manager ⇒ Object
readonly
Returns the value of attribute manager.
Attributes inherited from Buildkite::Builder::Extension
#context, #options, #options_block
Instance Method Summary collapse
Methods inherited from Buildkite::Builder::Extension
Constructor Details
This class inherits a constructor from Buildkite::Builder::Extension
Instance Attribute Details
#manager ⇒ Object (readonly)
Returns the value of attribute manager.
5 6 7 |
# File 'lib/buildkite/builder/extensions/plugins.rb', line 5 def manager @manager end |
Instance Method Details
#build ⇒ Object
17 18 19 20 21 22 23 24 25 26 |
# File 'lib/buildkite/builder/extensions/plugins.rb', line 17 def build context.data.steps.each(:command) do |step| next unless step.has?(:plugins) step.get(:plugins).map! do |plugin| resource, attributes = extract_resource_and_attributes(plugin) resource.is_a?(Symbol) ? manager.build(resource, attributes) : plugin end end end |
#prepare ⇒ Object
13 14 15 |
# File 'lib/buildkite/builder/extensions/plugins.rb', line 13 def prepare @manager = PluginManager.new end |