54 lines
1.3 KiB
Nix
54 lines
1.3 KiB
Nix
{
|
|
description = "Various dylint lints";
|
|
|
|
inputs = {
|
|
nixpkgs.url = "github:nixos/nixpkgs?ref=nixpkgs-unstable";
|
|
flake-utils.url = "github:numtide/flake-utils";
|
|
crane.url = "github:ipetkov/crane";
|
|
rust-overlay = {
|
|
url = "github:oxalica/rust-overlay";
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
};
|
|
dylint = {
|
|
url = "github:TheNeikos/nix-dylint";
|
|
inputs = {
|
|
nixpkgs.follows = "nixpkgs";
|
|
crane.follows = "crane";
|
|
rust-overlay.follows = "rust-overlay";
|
|
flake-utils.follows = "flake-utils";
|
|
};
|
|
};
|
|
};
|
|
|
|
outputs =
|
|
inputs:
|
|
inputs.flake-utils.lib.eachDefaultSystem (
|
|
system:
|
|
let
|
|
pkgs = import inputs.nixpkgs {
|
|
inherit system;
|
|
overlays = [
|
|
inputs.rust-overlay.overlays.default
|
|
];
|
|
};
|
|
|
|
rustTarget = pkgs.rust-bin.fromRustupToolchainFile ./rust-toolchain.toml;
|
|
|
|
dylintLib = inputs.dylint.mkLib {
|
|
inherit pkgs;
|
|
inherit (inputs) crane;
|
|
};
|
|
|
|
lints = [ ];
|
|
dylint = dylintLib.mkDylint { inherit lints; };
|
|
in
|
|
{
|
|
devShells.default = pkgs.mkShell {
|
|
nativeBuildInputs = [
|
|
rustTarget
|
|
dylint
|
|
];
|
|
};
|
|
}
|
|
);
|
|
}
|