I have a very simple task that I need to do. I have a Linux box (Debian, specifically) and I want it to watch a shared folder on a Windows server and, whenever a new file is uploaded to that folder, copy that file to a local folder.
A straight synchronization won't work as I don't want changes to be replicated back to the source folder (it's a one-way copy) and I don't want it to repeat copying a file that is deleted from the destination.
In other words, if somebody copies a file to \\windows\shared\watchme, that file needs to be copied over, one time to /home/debian/whatever. Then it will be altered or deleted on the Debian box, with no changes to the original.
If push comes to shove, I can write a PERL script that will do it, and schedule it as cron job to run every 5m. However, that's clumsy, and I'd like to know if there's a more elegant way to do it.
Posts
the "no true scotch man" fallacy.