in reply to Re: Globbing for file in an unkown directory path only works first time in foreach loop?
in thread Globbing for file in an unkown directory path only works first time in foreach loop?

Thank you Muskrat for your reply. I did infact include the actual code i was running, both in the reply to the post (Anonymous Monk on Jan 29, 2016 at 20:09 UTC) and in my edit to the OP. I've just had to change the directory paths/names to something else because of security/proprietary reasons.

I'm going to try your implementation now but one thing that i'm concnerned about in your code is you have the comment: # there may be multiple directories containing desired_file.txt

in the /home/myfiles/day_of_year/4257/ directory there are multiple folders. One of those folders (with unknown name) has a path that leads to the single file desired_file.txt.

  • Comment on Re^2: Globbing for file in an unkown directory path only works first time in foreach loop?