How to make Ruby's Find.find follow symlinks?
问题 I have a file hierarchy and some of the sub-directories are relative symlinks. I am using Ruby's Find.find to crawl through these dirs and find some specific files. However it's not looking into any directory which is a symlink (it follows files which are symlinks). Looking at the source code it seems the problem is because it's using File.lstat(file).directory? to test if something is a directory. This returns false for symlinks but File.stat.directory? returns true . How can I make Find