I would like to write a function to check if the contents of a directory, its files, have been changed. The idea is to check the directory every 2 minutes and take some actions if some files were updated or new files added.
Does anyone has any ideas? I was considering listing the files (name, date modified, size) on a variable array, then list again and compare both arrays. In case there are different, take some action. Thank you, C.F.