Dealing with files...
George Kinney
gk_2345 at yahoo.com
Fri Apr 25 22:13:35 EDT 2003
"lost" <lost at soul.net> wrote in message
news:pan.2003.04.25.23.29.48.204375 at soul.net...
> On Fri, 25 Apr 2003 22:51:12 +0000, Alex Martelli wrote:
> Hi Alex,
> sorry i wasn't a bit more specific in what i needed, but what you posted
> was exactly what i was looking for! Thanks a lot.
>
FWIW, theres also:
from glob import glob
file_list = glob.glob(SomePath)
outfile = open(OutputFilename, 'w')
for file in file_list :
print file
outfile.write(file + '\n')
outfile.close()
More information about the Python-list
mailing list