package irmin-mirage-git

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

Parameters

module C : Mirage_clock.PCLOCK

Signature

include Mirage_kv.RW
type nonrec error = private [>
  1. | Mirage_kv.error
]
val pp_error : error Fmt.t
type t
val disconnect : t -> unit Lwt.t
type key = Mirage_kv.Key.t
val exists : t -> key -> ([ `Dictionary | `Value ] option, error) Stdlib.result Lwt.t
val get : t -> key -> (string, error) Stdlib.result Lwt.t
val list : t -> key -> ((string * [ `Dictionary | `Value ]) list, error) Stdlib.result Lwt.t
val last_modified : t -> key -> (int * int64, error) Stdlib.result Lwt.t
val digest : t -> key -> (string, error) Stdlib.result Lwt.t
type nonrec write_error = private [>
  1. | Mirage_kv.write_error
]
val pp_write_error : write_error Fmt.t
val set : t -> key -> string -> (unit, write_error) Stdlib.result Lwt.t
val remove : t -> key -> (unit, write_error) Stdlib.result Lwt.t
val batch : t -> ?retries:int -> (t -> 'a Lwt.t) -> 'a Lwt.t
val connect : ?depth:int -> ?branch:string -> ?root:key -> ?ctx:Mimic.ctx -> ?headers:(string * string) list -> ?author:(unit -> string) -> ?msg:([ `Set of key | `Remove of key | `Batch ] -> string) -> G.t -> string -> t Lwt.t

connect ?depth ?branch ?path ?author ?msg g c uri clones the given uri into g repository, using the given branch, depth and '/'-separated sub-path. By default, branch is main, depth is 1 and path is empty, ie. reads will be relative to the root of the repository. author, msg and c are used to create new commit info values on every update. By defaut author is fun () -> "irmin" <irmin@mirage.io> and msg returns basic information about the kind of operations performed.

OCaml

Innovation. Community. Security.