package dune

  1. Overview
  2. Docs
Fast, portable and opinionated build system

Install

Dune Dependency

Authors

Maintainers

Sources

dune-build-info-1.11.4.tbz
sha256=77cb5f483221b266ded2b85fc84173ae0089a25134a086be922e82c131456ce6
sha512=02f00fd872aa49b832fc8c1e928409f23c79ddf84a53009a58875f222cca36fbb92c905e12c539caec9cbad723f195a8aa24218382dca35a903b3f52b11f06f2

doc/dune.configurator/Configurator/V1/Process/index.html

Module V1.Process

Execute external programs.

type result = {
  1. exit_code : int;
  2. stdout : string;
  3. stderr : string;
}
val run : t -> ?dir:string -> ?env:string list -> string -> string list -> result

run t prog args runs prog with arguments args and returns its exit status together with the content of stdout and stderr. The action is logged.

  • parameter dir

    change to dir before running the command.

  • parameter env

    specify additional environment variables as a list of the form NAME=VALUE.

val run_capture_exn : t -> ?dir:string -> ?env:string list -> string -> string list -> string

run_capture_exn t prog args same as run t prog args but returns stdout and die if the error code is nonzero or there is some output on stderr.

val run_ok : t -> ?dir:string -> ?env:string list -> string -> string list -> bool

run_ok t prog args same as run t prog args but only cares whether the execution terminated successfully (i.e., returned an error code of 0).

OCaml

Innovation. Community. Security.