WIP: Package cargo-dylint
This commit is contained in:
parent
a154eccfed
commit
05e39da57e
3 changed files with 28 additions and 2 deletions
|
|
@ -26,11 +26,15 @@
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
rustTarget = pkgs.rust-bin.fromRustupToolchainFile ./rust-toolchain.toml;
|
||||||
|
craneLib = (inputs.crane.mkLib pkgs).overrideToolchain rustTarget;
|
||||||
|
|
||||||
callPackage = pkgs.lib.callPackageWith (
|
callPackage = pkgs.lib.callPackageWith (
|
||||||
pkgs
|
pkgs
|
||||||
// {
|
// {
|
||||||
inherit
|
inherit
|
||||||
inputs
|
inputs
|
||||||
|
craneLib
|
||||||
;
|
;
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,28 @@
|
||||||
{
|
{
|
||||||
inputs,
|
pkgs,
|
||||||
|
craneLib,
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
|
|
||||||
{
|
let
|
||||||
|
pname = "cargo-dylint";
|
||||||
|
version = "4.0.0";
|
||||||
|
|
||||||
|
src = pkgs.fetchFromGitHub {
|
||||||
|
owner = "trailofbits";
|
||||||
|
repo = "dylint";
|
||||||
|
tag = "v${version}";
|
||||||
|
sha256 = "sha256-Z8uuewp7Buoadayc0oTafmfvwNT36KukWKiHxL/mQfI=";
|
||||||
|
};
|
||||||
|
|
||||||
|
cargoArtifacts = craneLib.buildDepsOnly {
|
||||||
|
inherit pname version src;
|
||||||
|
};
|
||||||
|
in craneLib.buildPackage {
|
||||||
|
inherit
|
||||||
|
cargoArtifacts
|
||||||
|
pname
|
||||||
|
version
|
||||||
|
src
|
||||||
|
;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
2
rust-toolchain.toml
Normal file
2
rust-toolchain.toml
Normal file
|
|
@ -0,0 +1,2 @@
|
||||||
|
[toolchain]
|
||||||
|
channel = "nightly-2025-03-01"
|
||||||
Loading…
Add table
Add a link
Reference in a new issue