Skip to content

Commit

Permalink
Fix pull, so that edges are added to version graph
Browse files Browse the repository at this point in the history
  • Loading branch information
octalsrc committed Nov 2, 2021
1 parent 2c7afc3 commit e55db24
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 4 deletions.
7 changes: 6 additions & 1 deletion mergedb.nix
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,10 @@ buildDunePackage rec {
version = "0";
src = ./src;
useDune2 = true;
buildInputs = [ ocaml-scylla ];
buildInputs = with ocamlPackages; [
ocaml-scylla
irmin
ppx_irmin
lwt_ppx
];
}
6 changes: 3 additions & 3 deletions ocaml-scylla.nix
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ with ocamlPackages;
let pname = "scylla";

repo = fetchFromGitHub {
owner = "anmolsahoo25";
owner = "gowthamk";
repo = "ocaml-${pname}";
rev = "1781f065d913d629052fdf06605de1a727cf5601";
sha256 = "05yjhn9hvfjnmkc2m1xb2xch54p8jqy6jyz6qak3rpyrfcdxk778";
rev = "65e87bdb61bde19fe2f50f77a6dc88c978445c68";
sha256 = "1dn8xdjazkizk8ik8cg5kr6p9jjglw9j2w63iq5p26pkkb5fjfrh";
};

in
Expand Down
6 changes: 6 additions & 0 deletions src/mergeDB.ml
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,12 @@ module Make (Data : Content.TYPE) = struct
in
(* Update head of into_b to the new version. *)
let _ = HeadMap.set db new_v in
(* Add new edges to version graph *)
let _ = VersionGraph.add_version
db
new_v
[from_v; into_v]
in
(* Update LCA between from_b and into_b, using from_b's head
as LCA version. *)
let _ = set_lca db from_b into_b from_v in
Expand Down

0 comments on commit e55db24

Please sign in to comment.