package volgo

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Vcs.GitSource

Manipulating the output of processes run by vcs and backends - typically the "git" command.

Sourcemodule Output : sig ... end
Sourcemodule type S = sig ... end

This is the interface commonly used by raising and non-raising helper modules, such as Vcs.Git, Volgo_base.Vcs.Git.Or_error, Vcs.Git.Result, Vcs.Git.Rresult, and custom ones built with Vcs.Git.Non_raising.Make. S is parametrized by the result type returned by the helpers.

The interface exposed at the top level of this module are helpers that return direct results, or raise Err.E. This module is exported to users as Vcs.Git.

The helpers are suitable for use in combination with the Vcs.git function, which will take care of wrapping the exception with useful context, before re-raising it.

include S with type 'a result := 'a
Sourceval exit0 : Output.t -> unit
Sourceval exit0_and_stdout : Output.t -> string
Sourceval exit_code : Output.t -> accept:(int * 'a) list -> 'a

A convenient wrapper to write exhaustive match on a result conditioned by a list of accepted exit codes. If the exit code is not part of the accepted list, the function takes care of returning an error of the expected result type.

Sourcemodule Non_raising : sig ... end

A functor to build non raising helpers based on a custom error type.

Sourcemodule Rresult : S with type 'a result := ('a, [ `Vcs of Err.t ]) Result.t

Helpers to wrap process outputs.

Sourcemodule Result : S with type 'a result := ('a, Err.t) Result.t

Helpers to wrap process outputs.

OCaml

Innovation. Community. Security.