We need to zip files having '2009' in their names from a particular directory. How can we do the same.
file = zipfile.ZipFile("test.zip", "w")
dirList = os.listdir(rawFileLocation)
for fnames in dirList:
It is zipping all the files. Please tell me the logic for adding files which fulfill certain criteria only.