X-Git-Url: https://git.hcoop.net/hcoop/domtool2.git/blobdiff_plain/d612d62cd04b713bb1057fd2e666365704aaf3d6..c9731b9b3ee43c4c8d82c31009a5870a01d3acfa:/src/slave.sig diff --git a/src/slave.sig b/src/slave.sig index 24082d4..b9abecd 100644 --- a/src/slave.sig +++ b/src/slave.sig @@ -27,6 +27,7 @@ signature SLAVE = sig type file_status = {action : file_action, domain : string, + dir : string, file : string} val registerFileHandler : (file_status -> unit) -> unit @@ -39,4 +40,24 @@ signature SLAVE = sig (* Register code to run before or after making all changes. *) val handleChanges : file_status list -> unit + + val shell : string list -> bool + val shellF : string list * (string -> string) -> unit + + val concatTo : (string -> bool) -> string -> unit + (* Search through the result configuration hierarchy for all files matching + * the predicate, concatenating their contents in arbitrary order to the + * given file. *) + + val enumerateTo : (string -> bool) -> string -> string -> unit + (* Search through the result configuration hierarchy for all files matching + * the predicate, writing a list of their domains to the file named by the + * third argument, delimiting the entries with the second argument. *) + + val hostname : unit -> string + (* Get hostname of this machine *) + + val readList : string -> string list + val writeList : string * string list -> unit + (* Reading and writing lists of strings stored on separate lines in files *) end