开发者

Monitoring files with twisted

Is it possible to write a Twisted application 开发者_Go百科to monitor addtion of new files/folders to a specific folder? If yes, could someone point me to some code/link trying to do it, or give an idea how to do that?


On Linux, you can have inotify with nice Twisted integration.

Hopefully someday there will be something similar for Windows and perhaps *BSD (based on kqueue), but for now Twisted only ships with support for this on Linux.


You do not need twisted, but of course you can integrate it. Basically you need yo use inotify.

Take a look at https://github.com/seb-m/pyinotify


Windows or linux?

Windows: http://tgolden.sc.sabren.com/python/win32_how_do_i/watch_directory_for_changes.html

Linux: http://www.lambda-computing.com/projects/dnotify/

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜