Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 buildNpmPackage, 4 fetchFromGitHub, 5 nix-update-script, 6}: 7 8buildNpmPackage (finalAttrs: { 9 pname = "hyperblobs"; 10 version = "2.8.0"; 11 12 src = fetchFromGitHub { 13 owner = "holepunchto"; 14 repo = "hyperblobs"; 15 tag = "v${finalAttrs.version}"; 16 hash = "sha256-cj716lDyQj7IVbAmfQaKagfR1+ZYoQgOTXIn/3d+KEA="; 17 }; 18 19 npmDepsHash = "sha256-9/hoj+ktd5DyBjGnhPFpC3b7A+XjWWoFhbvvW+o8DBc="; 20 21 dontNpmBuild = true; 22 23 doCheck = true; 24 25 checkPhase = '' 26 runHook preCheck 27 28 npm run test 29 30 runHook postCheck 31 ''; 32 33 postPatch = '' 34 cp ${./package-lock.json} ./package-lock.json 35 ''; 36 37 passthru.updateScript = nix-update-script { }; 38 39 meta = { 40 description = "Blob Store for Hypercore"; 41 homepage = "https://github.com/holepunchto/hyperblobs"; 42 license = lib.licenses.asl20; 43 platforms = lib.platforms.all; 44 teams = with lib.teams; [ ngi ]; 45 maintainers = with lib.maintainers; [ ]; 46 }; 47})