Patrick Useldinger wrote: > > fdups' homepage is at http://www.homepages.lu/pu/fdups.html, where > you'll also find a link to download the tar. >
"""fdups has no installation program. Just change into a temporary directory, and type "tar xfj fdups.tar.bz". You should also chown the files according to your needs, and then copy the executables to your PATH.""" (1) It's actually .bz2, not .bz (2) Why annoy people with the not-widely-known bzip2 format just to save a few % of a 12KB file?? (3) Typing that on Windows command line doesn't produce a useful result (4) Haven't you heard of distutils? (5) if files[subgroup[j]]['flag'] and files[subgroup[i]]['buffer'] == files[subgroup[j]]['buffer']: That's not the most readable code I've ever seen. (6) You are keeping open handles for all files of a given size -- have you actually considered the possibility of an exception like this: IOError: [Errno 24] Too many open files: 'foo509' Once upon a time, max 20 open files was considered as generous as 640KB of memory. Looks like Bill thinks 512 (open files, that is) is about right these days. (7) ! def compare(self): ! """ compare all files of the same size - outer loop """ ! sizes=self.compfiles.keys() ! sizes.sort() ! for size in sizes: ! self.comparefiles(size,self.compfiles[size]) Why sort? What's wrong with just two lines: ! for size, file_list in self.compfiles.iteritems(): ! self.comparefiles(size, file_list) (8) global MIN_FILESIZE,MAX_ONEBUFFER,MAX_ALLBUFFERS,BLOCKSIZE,INODES That doesn't sit very well with the 'everything must be in a class' religion seemingly espoused by the following: ! class fDups: ! """ encapsulates the whole logic """ (9) Any good reason why the "executables" don't have ".py" extensions on their names? All in all, a very poor "out-of-the-box" experience. Bear in mind that very few Windows users would have even heard of bzip2, let alone have a bzip2.exe on their machine. They wouldn't even be able to *open* the box. And what is "chown" -- any relation of Perl's "chomp"? -- http://mail.python.org/mailman/listinfo/python-list