ocamlPackages.semver: 0.1.0 → 0.2.1

This commit is contained in:
Vincent Laporte 2023-11-02 07:11:45 +01:00 committed by Vincent Laporte
parent c52cf53280
commit 07055fb3ec

View File

@ -1,29 +1,19 @@
{ stdenv, lib, fetchzip, ocaml, findlib, ocamlbuild }: { lib, fetchurl, buildDunePackage, ocaml, alcotest }:
lib.throwIfNot (lib.versionAtLeast ocaml.version "4.02") buildDunePackage rec {
"semver is not available on OCaml older than 4.02" pname = "semver";
version = "0.2.1";
stdenv.mkDerivation rec { src = fetchurl {
pname = "ocaml${ocaml.version}-semver"; url = "https://github.com/rgrinberg/ocaml-semver/releases/download/${version}/semver-${version}.tbz";
version = "0.1.0"; hash = "sha256-CjzDUtoe5Hvt6zImb+EqVIulRUUUQd9MmuJ4BH/2mLg=";
src = fetchzip {
url = "https://github.com/rgrinberg/ocaml-semver/archive/v${version}.tar.gz";
sha256 = "sha256-0BzeuVTpuRIQjadGg08hTvMzZtKCl2utW2YK269oETk=";
}; };
nativeBuildInputs = [ doCheck = lib.versionAtLeast ocaml.version "4.08";
ocaml checkInputs = [ alcotest ];
findlib
ocamlbuild
];
strictDeps = true;
createFindlibDestdir = true;
meta = { meta = {
homepage = "https://github.com/rgrinberg/ocaml-semver"; homepage = "https://github.com/rgrinberg/ocaml-semver";
description = "Semantic versioning module"; description = "Semantic versioning module";
platforms = ocaml.meta.platforms;
license = lib.licenses.bsd3; license = lib.licenses.bsd3;
maintainers = [ lib.maintainers.ulrikstrid ]; maintainers = [ lib.maintainers.ulrikstrid ];
}; };