Hi
I don't know if this is the right forum, but here goes:
How can you "watch" a file on Unix so that everytime the file gets modified, a script runs which does all sorts of stuff, like sending an e-mail notification, etc. to the administrator?
I suppose you can add this to the cron program to check every hour or so if the modified date of this file has changed, but I prefer to be notified immediately.
Thanks
Automatic notification when a file gets modified
Moderator: General Moderators
How about give people access only to a short Python (or perl or ruby or bash, you get the point) script that opens the file for them and sends you an email? that seems like an interesting tack.
Or, use a CVS system? I bet there's functions for that in a CVS system, but I couldn't tell you for sure.
Otherwise, maybe if you have people access the file through sudo it could send you a notification?
never set any of this up myself, just pointing in directions that I'd look (in order of precedence).
Good luck fixing it, find some unix gurus somewhere
Or, use a CVS system? I bet there's functions for that in a CVS system, but I couldn't tell you for sure.
Otherwise, maybe if you have people access the file through sudo it could send you a notification?
never set any of this up myself, just pointing in directions that I'd look (in order of precedence).
Good luck fixing it, find some unix gurus somewhere