Files
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

64 lines
1.7 KiB
Nix

{
lib,
fetchzip,
topkg,
buildTopkgPackage,
withBrr ? true,
brr,
withBytesrw ? true,
bytesrw,
withCmdliner ? true,
cmdliner,
}:
buildTopkgPackage rec {
pname = "jsont";
version = "0.2.0";
minimalOCamlVersion = "4.14.0";
src = fetchzip {
url = "https://erratique.ch/software/jsont/releases/jsont-${version}.tbz";
hash = "sha256-dXHl+bLuIrlrQ5Np37+uVuETFBb3j8XeDVEK9izoQFk=";
};
buildInputs = lib.optional withCmdliner cmdliner;
propagatedBuildInputs = lib.optional withBrr brr ++ lib.optional withBytesrw bytesrw;
buildPhase = "${topkg.run} build ${
lib.escapeShellArgs [
"--with-brr"
(lib.boolToString withBrr)
"--with-bytesrw"
(lib.boolToString withBytesrw)
"--with-cmdliner"
(lib.boolToString withCmdliner)
]
}";
meta = {
description = "Declarative JSON data manipulation";
longDescription = ''
Jsont is an OCaml library for declarative JSON data manipulation. it
provides:
Combinators for describing JSON data using the OCaml values of your
choice. The descriptions can be used by generic functions to decode,
encode, query and update JSON data without having to construct a
generic JSON representation
A JSON codec with optional text location tracking and best-effort
layout preservation. The codec is compatible with effect-based
concurrency.
The descriptions are independent from the codec and can be used by
third-party processors or codecs.
'';
homepage = "https://erratique.ch/software/jsont";
license = lib.licenses.isc;
maintainers = with lib.maintainers; [ toastal ];
};
}