A fast directory watcher in Clojure using directory-watcher. From its README:
A directory watcher utility for JDK 8+ that aims to provide accurate and efficient recursive watching for Linux, macOS and Windows. In particular, this library provides a JNA-based WatchService for Mac OS X to replace the default polling-based JDK implementation.
The core directory-watcher library is designed to have minimal dependencies; currently it only depends on slf4j-api (for internal logging, which can be disabled by passing a NOPLogger in the builder) and jna (for the macOS watcher implementation).
Developed by David Nolen & extracted from krell.
(require '[nextjournal.directory-watcher :as dw]
(def watcher
(doto (dw/create prn "src")
dw/watch))
(dw/stop watcher)
Can you improve this documentation?Edit on GitHub
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close