[EMAIL PROTECTED] wrote:
# i'm guessing os.walk() is the best way to traverse folder trees.
import os, glob
for dir, subdir, files in os.walk('.\InteropSolution'):
for file in files:
if glob.fnmatch.fnmatch(file,*.dll) or
glob.fnmatch.fnmatch(file,*.exe):
print
awesome. thanks.
--
http://mail.python.org/mailman/listinfo/python-list
i'm looking for something like glob.glob() that traverses
sub-directories. is there anything like that? i guess i'm looking for
something to replace the unix find command.
--
http://mail.python.org/mailman/listinfo/python-list
# i'm guessing os.walk() is the best way to traverse folder trees.
import os, glob
for dir, subdir, files in os.walk('.\InteropSolution'):
for file in files:
if glob.fnmatch.fnmatch(file,*.dll) or
glob.fnmatch.fnmatch(file,*.exe):
print dir+file
--