How to return path when doing directory recursion?

A related question: In the “do_stuff_here” part of
the for loop, is there a function I can call that
will return the path of the file being read?

How about using the file.path method :wink:

for f in Dir.glob("./some_directory/**/*")
File.open(f) { |file|
puts file.path
} if File.file?(f)
end

···

Do You Yahoo!?
Yahoo! Finance - Get real-time stock quotes
http://finance.yahoo.com