Class: ThorFoodCritic::Tasks

Inherits:
Thor
  • Object
show all
Defined in:
lib/thor-foodcritic.rb

Instance Method Summary collapse

Instance Method Details

#lintObject



39
40
41
42
43
44
45
46
47
48
49
50
# File 'lib/thor-foodcritic.rb', line 39

def lint
  review = ::FoodCritic::Linter.new.check(
    cookbook_paths: options[:cookbook_path],
    role_paths: options[:role_path],
    tags: options[:tags],
    include_rules: options[:include],
    fail_tags: options[:epic_fail],
    exclude_paths: options[:exclude_paths]
  )
  say(review, :red)
  exit_if_failure(review)
end