Class: Chef::Taste::Cli

Inherits:
Thor
  • Object
show all
Defined in:
lib/chef/taste/cli.rb

Overview

The CLI for chef-taste

Instance Method Summary collapse

Instance Method Details

#checkObject

The check command



43
44
45
46
47
48
49
50
51
52
53
54
# File 'lib/chef/taste/cli.rb', line 43

def check
  dependencies = DependencyChecker.check
  if dependencies.empty?
    puts 'No dependent cookbooks'.yellow
  else
    Display.print(dependencies, options[:format])
  end
rescue NotACookbookError
  puts 'The path is not a cookbook path'.red
rescue UnsupportedDisplayFormatError
  puts 'The display format is not supported'.red
end