Merge pull request 'Add the branch accessor' (#30) from add-branch-accessor into main

Reviewed-on: https://git.robur.io/robur/git-kv/pulls/30
This commit is contained in:
Reynir Björnsson 2023-03-16 11:12:55 +00:00
commit 0e6eab102f
2 changed files with 5 additions and 0 deletions

View file

@ -107,6 +107,8 @@ let connect ctx endpoint =
let _r = to_invalid r in
Lwt.return t
let branch t = t.branch
type key = Mirage_kv.Key.t
type change = [

View file

@ -40,6 +40,9 @@ val connect : Mimic.ctx -> string -> t Lwt.t
@raise [Invalid_argument _] if we can not initialize the store, or if
we can not fetch the given [remote]. *)
val branch : t -> Git.Reference.t
(** [branch t] returns the branch used by the given [t]. *)
val to_octets : t -> string Lwt.t
(** [to_octets store] returns a serialized version of the given [store]. *)