{"repo":"septag/dmon","free":true,"listed":false,"github":"https://github.com/septag/dmon","clone":"git clone https://github.com/septag/dmon.git","description":"Single header C99 portable library for monitoring filesystem changes. (Windows/Linux/MacOS)","language":"C","stars":289,"topics":["c","single-header-lib","os","filesystem","directory-monitoring","multiplatform","monitor","monitoring"],"license":"BSD-2-Clause","category":"analytics","readme_excerpt":"dmon @septag dmon is a tiny C library that monitors changes in a directory. It provides a unified solution to multiple system APIs that exist for each OS. It can also monitor directories recursively. Platforms - Windows: ReadDirectoryChangesW backend. Tested with Windows10 SDK + Visual Studio 2019 - Linux: inotify backend. Tested with gcc-7.4/clang-6, ubuntu 18.04 LTS - FreeBSD (as of 15.0): Compatibilty with Linux's inotify interface. Tested with gcc14.2/clang-19.1 - MacOS: FSEvents backend. Tested with MacOS-10.14 clang 10 Usage You just have to include the file and use it's functions. It is also compatible with C++ code. Backslashes in Windows paths are also converted to '/' for portability. For more information and how to customize functionality, see dmon.h Build Example - Windows: - Linux/Unix: - MacOS: INotify backend Extras NOTE : If you want to compile with c11 standard, you need to add gnu compiler extensions as well, otherwise you will get compilation errors. So the compilation command for test example would be: There is this other file dmon extra.h that you can include optionally after dmon.h for inotify backend. There are two APIs that are introduced in that header, dmon watch add and dmon watch rm in which you can add/remove sub-directories to currently watched directory. This can be useful in cases where there are large set of changes happening on inotify backend and you won't get all the events, because of some drawbacks of the inotify backend. So, by disabling","default_branch":null,"files":null,"tree":[],"storefront":"/r/septag","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/septag/dmon/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}