def relevant_output(lint, files)
        all_files = {}
        files.each do |file|

          # sometimes data will be blank but this is good - it means no errors were raised in the lint
          next if lint.blank? || file.blank? || !file.is_a?(Hash) || !file.key?(:filename)
          lint_file = lint[file[:filename]]

          next if lint_file.blank?

          expanded = lines_added_to_range(file)
          revert_name = strip_working_dir(file[:filename])

          all_files[revert_name] = []

          lint_file.each do |l|
            if expanded.include?(l['line'].to_i)
              all_files[revert_name] << l
            end
          end

          # If there's nothing there, then it definitely isn't a relevant lint
          all_files.delete(revert_name) if all_files[revert_name].blank?
        end
        @output[:files_linted] = all_files.keys
        all_files
      end
def relevant_output(lint, files)
        all_files = {}
        files.each do |file|

          # sometimes data will be blank but this is good - it means no errors were raised in the lint
          next if lint.blank? || file.blank? || !file.is_a?(Hash) || !file.key?(:filename)
          lint_file = lint[file[:filename]]

          next if lint_file.blank?

          expanded = lines_added_to_range(file)
          revert_name = strip_working_dir(file[:filename])

          all_files[revert_name] = []

          lint_file.each do |l|
            if expanded.include?(l['line'].to_i)
              all_files[revert_name] << l
            end
          end

          # If there's nothing there, then it definitely isn't a relevant lint
          all_files.delete(revert_name) if all_files[revert_name].blank?
        end
        @output[:files_linted] = all_files.keys
        all_files
      end
Compare lint output with lines changed in commit
 @param lint [Hash] output lint data
 @param files [Hash<String: String>] filename: filepath
 @return [Array] lints that match the lines in commit