class Utils::Finder

def attempt_match?(path)

def attempt_match?(path)
  stat = File.stat(path)
  stat.symlink? and stat = File.lstat(path)
  if @only_directory
    stat.directory?
  elsif @directory
    stat.directory? || ascii_file?(stat, path)
  else
    ascii_file?(stat, path)
  end
rescue SystemCallError => e
  warn "Caught #{e.class}: #{e}"
  nil
end