Python library to detect if a file has changed between different runs?

Posted by Stefano Borini on Stack Overflow See other posts from Stack Overflow or by Stefano Borini
Published on 2009-12-16T05:45:36Z Indexed on 2014/06/11 21:26 UTC
Read the original article Hit count: 179

Filed under:
|

Suppose I have a program A. I run it, and performs some operation starting from a file foo.txt. Now A terminates.

New run of A. It checks if the file foo.txt has changed. If the file has changed, A runs its operation again, otherwise, it quits.

Does a library function/external library for this exists ?

Of course it can be implemented with an md5 + a file/db containing the md5. I want to prevent reinventing the wheel.

© Stack Overflow or respective owner

Related posts about python

Related posts about file