renaming files

Mark McEahern marklists at mceahern.com
Tue Jan 7 05:54:10 CET 2003


> I can't find no easy way. I don't want to use a system call to 
> 'ls', so got a list of files with os.listdir(), but how can I 
> get a selective list?

import glob
for name in glob.glob('*.whatever'):
  print name

// m
-






More information about the Python-list mailing list