Merge pull request 'Fix the pull and usage of branch' (#4) from fix-pull into main
Reviewed-on: https://git.robur.io/robur/git-kv/pulls/4
This commit is contained in:
commit
eba43a65cb
1 changed files with 2 additions and 2 deletions
|
@ -32,7 +32,7 @@ let split_url s =
|
||||||
match String.split_on_char '#' s with
|
match String.split_on_char '#' s with
|
||||||
| [ edn; branch ] ->
|
| [ edn; branch ] ->
|
||||||
Smart_git.Endpoint.of_string edn |> to_invalid,
|
Smart_git.Endpoint.of_string edn |> to_invalid,
|
||||||
Git.Reference.of_string branch |> to_invalid
|
Git.Reference.of_string ("refs/heads/" ^ branch) |> to_invalid
|
||||||
| _ ->
|
| _ ->
|
||||||
Smart_git.Endpoint.of_string s |> to_invalid, main
|
Smart_git.Endpoint.of_string s |> to_invalid, main
|
||||||
|
|
||||||
|
@ -69,7 +69,7 @@ let diff store commit0 commit1 = match commit0 with
|
||||||
|
|
||||||
let pull t =
|
let pull t =
|
||||||
let open Lwt.Infix in
|
let open Lwt.Infix in
|
||||||
Sync.fetch ~capabilities ~ctx:t.ctx t.edn t.store ~deepen:(`Depth 1) `All >>= fun r ->
|
Sync.fetch ~capabilities ~ctx:t.ctx t.edn t.store ~deepen:(`Depth 1) (`Some [ t.branch, t.branch ]) >>= fun r ->
|
||||||
let data =
|
let data =
|
||||||
Result.map_error
|
Result.map_error
|
||||||
(fun e -> `Msg (Fmt.str "error fetching: %a" Sync.pp_error e))
|
(fun e -> `Msg (Fmt.str "error fetching: %a" Sync.pp_error e))
|
||||||
|
|
Loading…
Reference in a new issue