Class: Terraspace::Terraform::Tfc::Runs::Pruner

Inherits:
Base
  • Object
show all
Includes:
Api::Client
Defined in:
lib/terraspace/terraform/tfc/runs/pruner.rb

Instance Method Summary collapse

Methods included from Api::Client

#api, #backend, #build, #remote, #workspace_name

Methods inherited from Base

#build_project, #runs

Methods included from Util::Sure

#sure?

Methods included from Util::Logging

#logger

Constructor Details

#initialize(mod, options = {}) ⇒ Pruner

Returns a new instance of Pruner.



6
7
8
9
# File 'lib/terraspace/terraform/tfc/runs/pruner.rb', line 6

def initialize(mod, options={})
  super
  @queue, @kept, @needs_pruning = [], nil, false
end

Instance Method Details

#runObject



11
12
13
14
15
16
# File 'lib/terraspace/terraform/tfc/runs/pruner.rb', line 11

def run
  build_project
  build_queue
  are_you_sure?
  process_queue
end