1{ lib, fetchFromGitHub, ncurses, ocamlPackages }:
2
3with ocamlPackages; buildDunePackage rec {
4 pname = "ocaml-top";
5 version = "1.2.0";
6
7 duneVersion = "3";
8
9 src = fetchFromGitHub {
10 owner = "OCamlPro";
11 repo = "ocaml-top";
12 rev = version;
13 hash = "sha256-xmPGGB/zUpfeAxUIhR1PhfoESAJq7sTpqHuf++EH3Lw=";
14 };
15
16 nativeBuildInputs = [ ocp-build ];
17 buildInputs = [ ncurses lablgtk3-sourceview3 ocp-index ];
18
19 configurePhase = ''
20 export TERM=xterm
21 ocp-build -init
22 '';
23
24 meta = {
25 homepage = "https://www.typerex.org/ocaml-top.html";
26 license = lib.licenses.gpl3;
27 description = "A simple cross-platform OCaml code editor built for top-level evaluation";
28 maintainers = with lib.maintainers; [ vbgl ];
29 };
30}