I want to iterate through every jpg/jpeg file in a directory and every subdirectory and every subdirectory of that sub-directory and so on. I want to be able to go through every single image file in a folder. Is there an easy way to do this or would a recursive method work best?
Dir.glob("your_directory/**/*.{jpg,jpeg}")
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With