2019-06-16 20:59:06 +01:00
|
|
|
{ stdenv, fetchFromGitHub, ocaml, findlib, pcre, uutf }:
|
2015-05-15 16:55:37 +01:00
|
|
|
|
2018-07-29 20:18:09 +01:00
|
|
|
if !stdenv.lib.versionAtLeast ocaml.version "4.02"
|
|
|
|
then throw "jingoo is not available for OCaml ${ocaml.version}"
|
|
|
|
else
|
2015-05-15 16:55:37 +01:00
|
|
|
|
2018-07-29 20:18:09 +01:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "ocaml${ocaml.version}-jingoo-${version}";
|
|
|
|
version = "1.2.18";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "tategakibunko";
|
|
|
|
repo = "jingoo";
|
|
|
|
rev = "v${version}";
|
|
|
|
sha256 = "0gciiysrjy5r4yiisc41k4h0p530yawzqnr364xg8fdkk444fgkn";
|
2015-05-15 16:55:37 +01:00
|
|
|
};
|
|
|
|
|
2018-07-29 20:18:09 +01:00
|
|
|
buildInputs = [ ocaml findlib ];
|
|
|
|
propagatedBuildInputs = [ pcre uutf ];
|
2015-05-15 16:55:37 +01:00
|
|
|
|
2018-07-29 20:18:09 +01:00
|
|
|
createFindlibDestdir = true;
|
2015-05-15 16:55:37 +01:00
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
homepage = https://github.com/tategakibunko/jingoo;
|
|
|
|
description = "OCaml template engine almost compatible with jinja2";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = [ maintainers.ericbmerritt ];
|
|
|
|
};
|
|
|
|
}
|