如何订阅文件创建事件? (MacOS,Linux)

Is it possible to subscribe to the creation of a file with a given Filepath, without doing a polling every X time (MacOS,Linux) ?

1 - Do you know a haskell lib doing it ? Something like subscribe :: FilePath -> IO () ?

2-如果不是,您可以使用一些系统调用吗?

评论