mirror of
https://github.com/ipetkov/crane.git
synced 2024-11-29 10:42:21 +03:00
32 lines
412 B
Nix
32 lines
412 B
Nix
{ cargo
|
|
, clippy
|
|
, mkShell
|
|
, rustc
|
|
, rustfmt
|
|
}:
|
|
|
|
{ checks ? { }
|
|
, inputsFrom ? [ ]
|
|
, packages ? [ ]
|
|
, ...
|
|
}@args:
|
|
let
|
|
inherit (builtins) removeAttrs;
|
|
|
|
cleanedArgs = removeAttrs args [
|
|
"checks"
|
|
"inputsFrom"
|
|
"nativeBuildInputs"
|
|
];
|
|
in
|
|
mkShell (cleanedArgs // {
|
|
inputsFrom = builtins.attrValues checks ++ inputsFrom;
|
|
|
|
packages = [
|
|
rustc
|
|
cargo
|
|
clippy
|
|
rustfmt
|
|
] ++ packages;
|
|
})
|