Class: Chef::Knife::CookbookStats

Inherits:
Chef::Knife show all
Defined in:
lib/chef/knife/cookbook_stats.rb

Instance Method Summary collapse

Instance Method Details

#runObject



22
23
24
25
26
27
28
29
30
# File 'lib/chef/knife/cookbook_stats.rb', line 22

def run
  Shef::Extensions.extend_context_object(self)
  validate_options
  
  cookbook_hash = build_cookbook_hash
  cookbook_hash = filter_cookbook_hash(cookbook_hash) if config[:role]
  
  puts cookbook_hash.to_yaml
end