johnae / spook

Lightweight programmable evented utility based on LuaJIT and ljsyscall
Other
35 stars 0 forks source link

Consider moving away from libuv #9

Closed johnae closed 7 years ago

johnae commented 8 years ago

Using something built only for fs change notifications would reduce binary size and probably be give more information about "what happened". This could be one option:

https://github.com/emcrisostomo/fswatch

Another option might be to simply use ffi and hook into whatever notification system the fs has.

johnae commented 8 years ago

Or maybe https://github.com/passcod/rsnotify which is written in rust but with a less restrictive license.

johnae commented 8 years ago

This might be a fun thing to do but also sort of pointless. The binary isn't very large and we get lots of nice features with libuv.

johnae commented 8 years ago

One project that may be interesting is cqueues: http://25thandclement.com/%7Ewilliam/projects/cqueues.pdf and https://github.com/wahern/cqueues

As long as Windows support isn't interesting at least. Tbh there's already a dependency on ljsyscall (though only very limited usage) so Windows wouldn't "just work" anyway.

johnae commented 7 years ago

This will most probably be done using direct system calls instead as it provides the most control. I already have a somewhat working prototype for Linux and a branch will be up relatively soon. It also has the nice property of removing dependencies. There will be no libuv or cqueues dependency when this is done, only luajit and some vendored lua code.

johnae commented 7 years ago

Ongoing work in https://github.com/johnae/spook/pull/19

johnae commented 7 years ago

Done as of 0.7.0.