I'm looking to write a daemon/service with the ability to effectively watch multiple files for changes and trigger an event when the file is written. The issue here is that for what I have in mind, I might be tracking potentially hundreds of files on my relatively weak computer and I'm worried about performance issues.
I was thinking about using fswatch
, but I'm not sure about the performance given that are various types of monitors for different operating systems and especially for potentially hundreds of files.
I'm looking for a cross-platform solution. Preferably C++ or Nodejs. Any help would be very much appreciated!