by Chris Zheng, on random
These days, so many leiningen tools have a watch function - usually for plugins. When I run
lein <command> watch, a process is spawned that looks at a directory, sees what files are changed and then does something with them. Most have to do with testing and documentation but tools like these are also slipping into development.
This is a really simple pattern and it should be standard but unfortunately it is not. Here are a bunch of implementations when I search for file watch clojure on google.
I am sure there are many more libaries that implement this type of functionality. They all solve the same problem - Watch the directory for files that have changed; If files are changed, reload the files.
Node has an standard implementation clojure needs one too. Desperately.