[Unison-hackers] unison and inotify principle

Benjamin Pierce bcpierce at cis.upenn.edu
Wed Jun 4 13:40:31 EDT 2008


Hi Sylvain,

>> I am a very humble user who just want to comment on this design (take
> all of this conditionaly -- if you feel this is just silly, forget  
> about
> it).
>
> I don't like the idea of the "file which should be a newline-separated
> list of paths (relative to the root of the synchronization)".
>
> My idea is the following:
> - use "-repeat FOO" but FOO is a program
> - FOO read file scanned by unison on stdin
> - if FOO detects a change in a file scanned by UNISON, it writes it on
>  stdout
>
> In this design, unison has just to send absolute filename name to FOO
> and wait for FOO to write any notification.

I'm all in favor of simplicity, but I'm concerned about a couple of  
points in this design.

1) How is Unison going to hear about added files?

2) Is Unison really going to tell FOO about *every* file it scans?   
There may be very many of these (I haven't counted, but I'll bet there  
are more than 100k files in my filesystem).

    - Benjamin

>
>
> Moreover, you will just have to use "Unix.open_process" which is one  
> of
> the fully portable function (at least Linux/Windows) of the Unix  
> module.
>
> Regards
> Sylvain Le Gall
>
> ps: the solution is less simple than the other but external  
> notification
> program is easier to write and notification is more efficient.
>
> _______________________________________________
> Unison-hackers mailing list
> Unison-hackers at lists.seas.upenn.edu
> http://lists.seas.upenn.edu/mailman/listinfo/unison-hackers



More information about the Unison-hackers mailing list