2022-10-30 15:09:59 +00:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub, fetchpatch, testers, go-jsonnet }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-10-30 15:09:59 +00:00
|
|
|
buildGoModule rec {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "go-jsonnet";
|
2022-10-30 15:09:59 +00:00
|
|
|
version = "0.19.1";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "google";
|
2022-10-06 18:32:54 +00:00
|
|
|
repo = pname;
|
2020-04-24 23:36:52 +00:00
|
|
|
rev = "v${version}";
|
2022-10-30 15:09:59 +00:00
|
|
|
hash = "sha256-FgQYnas0qkIedRAA8ApZXLzEylg6PS6+8zzl7j+yOeI=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
vendorHash = "sha256-j1fTOUpLx34TgzW94A/BctLrg9XoTtb3cBizhVJoEEI=";
|
2022-10-30 15:09:59 +00:00
|
|
|
|
2022-10-06 18:32:54 +00:00
|
|
|
patches = [
|
2022-10-30 15:09:59 +00:00
|
|
|
# See https://github.com/google/go-jsonnet/issues/653.
|
2022-10-06 18:32:54 +00:00
|
|
|
(fetchpatch {
|
2022-10-30 15:09:59 +00:00
|
|
|
url = "https://github.com/google/go-jsonnet/commit/5712f2ed2c8dfa685e4f1234eefc7690a580af6f.patch";
|
|
|
|
hash = "sha256-/+6BlAaul4FoD7pq7yAy1xG78apEBuH2LC4fsfbugFQ=";
|
2022-10-06 18:32:54 +00:00
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2022-03-10 19:12:11 +00:00
|
|
|
subPackages = [ "cmd/jsonnet*" ];
|
|
|
|
|
2022-04-27 09:35:20 +00:00
|
|
|
passthru.tests.version = testers.testVersion {
|
2022-10-30 15:09:59 +00:00
|
|
|
package = go-jsonnet;
|
2022-03-10 19:12:11 +00:00
|
|
|
version = "v${version}";
|
|
|
|
};
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "An implementation of Jsonnet in pure Go";
|
|
|
|
homepage = "https://github.com/google/go-jsonnet";
|
|
|
|
license = licenses.asl20;
|
2022-03-10 19:12:11 +00:00
|
|
|
maintainers = with maintainers; [ nshalman aaronjheng ];
|
|
|
|
mainProgram = "jsonnet";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
2022-10-30 15:09:59 +00:00
|
|
|
}
|