dimanche 11 janvier 2015

Python filecmp.cmp('old_index.html', 'new_index.html') in if event

how can I make this python command in a if question:



import filecmp
filecmp.cmp('old_index.html', 'new_index.html')


the answer from these command is True or False. So that I can execute something when the files are the same or when they are not.


Thanks for your help


Aucun commentaire:

Enregistrer un commentaire