lib/puppet-check/ruby_parser.rb in puppet-check-1.2.0 vs lib/puppet-check/ruby_parser.rb in puppet-check-1.2.1

- old
+ new

@@ -74,10 +74,10 @@ if PuppetCheck.style_check require 'rubocop' # check Rubocop rubocop_args = PuppetCheck.rubocop_args.clone - # RuboCop is confused about the first 'mod' argument in librarian puppet (and first requires in Rakefiles and Gemfiles) so disable the Style/FileName check + # RuboCop is grumpy about non-snake_case filenames so disable the Style/FileName check rubocop_args.include?('--except') ? rubocop_args[rubocop_args.index('--except') + 1] = "#{rubocop_args[rubocop_args.index('--except') + 1]},Style/FileName" : rubocop_args.concat(['--except', 'Style/FileName']) warnings = Utils.capture_stdout { RuboCop::CLI.new.run(rubocop_args + ['--format', 'emacs', file]) } # collect style warnings next PuppetCheck.warning_files.push("-- #{file}:\n#{warnings.split("#{File.absolute_path(file)}:").join('')}") unless warnings.empty?