Module Shell.Process
Process dispatching
type status
=[
|
`Timeout of Core.Time.Span.t
|
`Exited of int
|
`Signaled of Core.Signal.t
]
The termination status of a process. This is an extension of
Unix.Process_status.t
to allow timeouts.
exception
Failed of result
val to_string : t -> string
val status_to_string : status -> string
val set_defaults : ?timeout:Core.Time.Span.t option -> ?verbose:bool -> ?echo:bool -> ?preserve_euid:bool -> unit -> unit
val format_failed : result -> string
val cmd : string -> string list -> t
val shell : string -> t
val make_ssh_command : ?ssh_options:string list -> ?quote_args:bool -> ?user:string -> host:string -> string list -> t
val remote : ?ssh_options:string list -> ?quote_args:bool -> ?user:string -> host:string -> t -> t
val content : string reader
val content_and_stderr : (string * string) reader
val discard : unit reader
val lines : ?eol:char -> unit -> string list reader
val head : ?eol:char -> unit -> string option reader
val head_exn : ?eol:char -> unit -> string reader
val one_line : ?eol:char -> unit -> string Core.Or_error.t reader
val one_line_exn : ?eol:char -> unit -> string reader
val callback : add:(Core.Bytes.t -> int -> unit) -> flush:(unit -> unit) -> unit reader
val callback_with_stderr : add:(Core.Bytes.t -> int -> unit) -> add_err:(Core.Bytes.t -> int -> unit) -> flush:(unit -> unit) -> unit reader
val run : (t -> 'a reader -> 'a) with_run_flags
val run_k : ((t -> 'a reader -> 'a) -> 'b) -> 'b with_run_flags
val test : (t -> bool) with_test_flags
val test_k : ((t -> bool) -> 'a) -> 'a with_test_flags