Class: KnifeSpork::SporkCheck

Inherits:
Chef::Knife
  • Object
show all
Includes:
Runner
Defined in:
lib/chef/knife/spork-check.rb

Instance Method Summary collapse

Methods included from Runner

included

Instance Method Details

#runObject



19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
# File 'lib/chef/knife/spork-check.rb', line 19

def run
  self.config = Chef::Config.merge!(config)

  if name_args.empty?
    ui.fatal 'You must specify a cookbook name!'
    show_usage
    exit(1)
  end

  #First load so plugins etc know what to work with
  initial_load
  
  run_plugins(:before_check)

  #Reload cookbook in case a VCS plugin found updates
  initial_load

  check
  run_plugins(:after_check)
end