2021-07-03 03:11:41 +00:00
|
|
|
{ buildGoModule, fetchFromGitHub, lib }:
|
|
|
|
|
2022-11-21 17:40:18 +00:00
|
|
|
let
|
|
|
|
version = "1.4.1";
|
|
|
|
in
|
|
|
|
buildGoModule {
|
2021-07-03 03:11:41 +00:00
|
|
|
pname = "yajsv";
|
|
|
|
version = version;
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "neilpa";
|
|
|
|
repo = "yajsv";
|
|
|
|
rev = "v${version}";
|
2022-11-21 17:40:18 +00:00
|
|
|
hash = "sha256-dp7PBN8yR+gPPUWA+ug11dUN7slU6CJAojuxt5eNTxA=";
|
2021-07-03 03:11:41 +00:00
|
|
|
};
|
|
|
|
|
2022-11-21 17:40:18 +00:00
|
|
|
vendorHash = "sha256-f45climGKl7HxD+1vz2TGqW/d0dqJ0RfvgJoRRM6lUk=";
|
2022-06-16 17:23:12 +00:00
|
|
|
|
2022-11-21 17:40:18 +00:00
|
|
|
ldflags = [ "-s" "-w" ];
|
2021-07-03 03:11:41 +00:00
|
|
|
|
|
|
|
doInstallCheck = true;
|
2022-11-21 17:40:18 +00:00
|
|
|
|
2021-07-03 03:11:41 +00:00
|
|
|
installCheckPhase = ''
|
|
|
|
$out/bin/yajsv -v > /dev/null
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Yet Another JSON Schema Validator";
|
|
|
|
homepage = "https://github.com/neilpa/yajsv";
|
|
|
|
license = lib.licenses.mit;
|
|
|
|
maintainers = with lib.maintainers; [ rycee ];
|
|
|
|
};
|
|
|
|
}
|