forked from nix-community/rnix-lsp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
flake.nix
39 lines (35 loc) · 1.05 KB
/
flake.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
{
description = "A work-in-progress language server for Nix, with syntax checking and basic completion";
inputs = {
naersk.url = "github:nix-community/naersk";
utils.url = "github:numtide/flake-utils";
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
naersk.inputs.nixpkgs.follows = "nixpkgs";
};
outputs = { self, nixpkgs, utils, naersk }:
utils.lib.eachDefaultSystem (system:
let
pkgs = nixpkgs.legacyPackages."${system}";
naersk-lib = naersk.lib."${system}";
in
rec {
packages.rnix-lsp = naersk-lib.buildPackage {
pname = "rnix-lsp";
root = ./.;
doCheck = true;
checkInputs = [ pkgs.nix ];
};
defaultPackage = packages.rnix-lsp;
devShell = pkgs.mkShell {
nativeBuildInputs = with pkgs; [
rustc
cargo
gitAndTools.pre-commit
];
};
apps.rnix-lsp = utils.lib.mkApp {
drv = packages.rnix-lsp;
};
defaultApp = apps.rnix-lsp;
});
}