From bc33b23cd057f13060e69cc65157b233d7be7fc0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Romildo=20Malaquias?= Date: Tue, 2 Feb 2021 08:29:15 -0300 Subject: [PATCH] ppx_deriving_cmdliner: init at 0.6.0 --- .../ppx_deriving_cmdliner/default.nix | 41 +++++++++++++++++++ pkgs/top-level/ocaml-packages.nix | 2 + 2 files changed, 43 insertions(+) create mode 100644 pkgs/development/ocaml-modules/ppx_deriving_cmdliner/default.nix diff --git a/pkgs/development/ocaml-modules/ppx_deriving_cmdliner/default.nix b/pkgs/development/ocaml-modules/ppx_deriving_cmdliner/default.nix new file mode 100644 index 000000000000..412ef9568db2 --- /dev/null +++ b/pkgs/development/ocaml-modules/ppx_deriving_cmdliner/default.nix @@ -0,0 +1,41 @@ +{ lib +, buildDunePackage +, fetchFromGitHub +, alcotest +, cmdliner +, ppx_deriving +, ppxlib +}: + +buildDunePackage rec { + pname = "ppx_deriving_cmdliner"; + version = "0.6.0"; + + minimumOCamlVersion = "4.08"; + useDune2 = true; + + src = fetchFromGitHub { + owner = "hammerlab"; + repo = "ppx_deriving_cmdliner"; + rev = "v${version}"; + sha256 = "19l32y2wv64d1c7fvln07dg3bkf7wf5inzjxlff7lbabskdbbras"; + }; + + propagatedBuildInputs = [ + cmdliner + ppx_deriving + ppxlib + ]; + + doCheck = true; + checkInputs = [ + alcotest + ]; + + meta = with lib; { + description = "Ppx_deriving plugin for generating command line interfaces from types for OCaml"; + inherit (src.meta) homepage; + license = licenses.asl20; + maintainers = [ maintainers.romildo ]; + }; +} diff --git a/pkgs/top-level/ocaml-packages.nix b/pkgs/top-level/ocaml-packages.nix index 6ae5f43a63c7..71da1aa5c0ae 100644 --- a/pkgs/top-level/ocaml-packages.nix +++ b/pkgs/top-level/ocaml-packages.nix @@ -1076,6 +1076,8 @@ let ppx_deriving_yojson = callPackage ../development/ocaml-modules/ppx_deriving_yojson {}; + ppx_deriving_cmdliner = callPackage ../development/ocaml-modules/ppx_deriving_cmdliner {}; + ppx_gen_rec = callPackage ../development/ocaml-modules/ppx_gen_rec {}; ppx_import = callPackage ../development/ocaml-modules/ppx_import (