Christopher De Vries <[EMAIL PROTECTED]> writes: > I'm not sure if there is a canonical method, but I would > recommending using a generator to get something like this, where 'f' > is a file object:
Thanks for the generator. It returns an extra blank line at the end when used with "find -print0", which is probably not ideal, and is also not how the normal file line iterator behaves. But don't worry -- I can fix it. In any case, as a suggestion to the whomever it is that arranges for stuff to be put into the standard library, there should be something like this there, so everyone doesn't have to reinvent the wheel (even if it's an easy wheel to reinvent) for something that any sysadmin (and many other users) would want to do on practically a daily basis. |>oug -- http://mail.python.org/mailman/listinfo/python-list