hoarder: 0.21.0 -> 0.22.0
[NixPkgs.git] / pkgs / by-name / ni / nil / package.nix
blob9d9a59704211a7493c2a04da8ce51390d5fff5c4
2   lib,
3   rustPlatform,
4   fetchFromGitHub,
5   nixVersions,
6   nix-update-script,
7 }:
9 rustPlatform.buildRustPackage rec {
10   pname = "nil";
11   version = "2024-08-06";
13   src = fetchFromGitHub {
14     owner = "oxalica";
15     repo = pname;
16     rev = version;
17     hash = "sha256-DqsN/VkYVr4M0PVRQKXPPOTaind5miYZURIYqM4MxYM=";
18   };
20   useFetchCargoVendor = true;
21   cargoHash = "sha256-7TR/xTc66WpPszJDrpisVvHXl2+FGrUOskZAkGyY04Q=";
23   nativeBuildInputs = [
24     (lib.getBin nixVersions.latest)
25   ];
27   env.CFG_RELEASE = version;
29   # might be related to https://github.com/NixOS/nix/issues/5884
30   preBuild = ''
31     export NIX_STATE_DIR=$(mktemp -d)
32   '';
34   passthru.updateScript = nix-update-script { };
36   meta = with lib; {
37     description = "Yet another language server for Nix";
38     homepage = "https://github.com/oxalica/nil";
39     changelog = "https://github.com/oxalica/nil/releases/tag/${version}";
40     license = with licenses; [
41       mit
42       asl20
43     ];
44     maintainers = with maintainers; [
45       figsoda
46       oxalica
47     ];
48     mainProgram = "nil";
49   };