I need to check if the file that existed in the directory on the server, the same file that was there 5 minutes ago?
In a specific directory, I delete and recreate a file with the same name every few minutes. A script is accessing a file every 2 minutes. So, at time t, the script checks the file and does the stuff. Then, at time t + 1, the file is deleted and recreated (with the same name, but possibly with different content). Then at time t + 2, the script again searches for the file.
So, in the second check, is there a way to check if the file has been modified or not (without reading the contents)?
source
share