X-Git-Url: https://git.hcoop.net/hcoop/domtool2.git/blobdiff_plain/ed9fda3a0e2edcf4ed546e0eb9ac128865538276..e1b99e23f8d30efc7842ee006e0ff3ef0347b7df:/src/slave.sig diff --git a/src/slave.sig b/src/slave.sig index 52c9381..1a11e51 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 @@ -52,4 +53,24 @@ signature SLAVE = sig (* 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 *) + + val lineInFile : string -> string -> bool + (* Is there a line in the file (first arg) that matches that given? *) + + val inGroup : {user : string, group : string} -> bool + (* Check membership in a UNIX group. *) + + val mkDirAll : string -> unit + (* [mkDirAll p] creates directory "p", creating all parent directories, as + * necessary. *) + + val remove : ''a list * ''a -> ''a list + val removeDups : ''a list -> ''a list end