I am new to Ruby, and I am trying to figure out a few things. My current problem is this: What is the easiest way to enter a directory (given as a command line argument), run every .rb
file in the folder, and gather the results. The program should write every result in a format like "filename :: OK" or "filename :: WRONG" depending on the result.
I use system ("ruby filename.rb")
to run the files, and Dir.chdir("Folder")
to get in the folder, but I have no idea how to iterate through them, and work them out. Any suggestions?