How can you find the most recently modified folder (NOT A FILE) in a directory using Ruby?
Find the most recently modified directory in the current directory:
folders = Dir["*"].delete_if{|entry| entry.include? "."} newest = folders[0] folders.each{|folder| newest = folder if File.mtime(folder) > File.mtime(newest)}