mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-07-06 17:13:24 -05:00
58 lines
1.2 KiB
Nix
58 lines
1.2 KiB
Nix
{
|
|
lib,
|
|
rustPlatform,
|
|
fetchFromGitHub,
|
|
pkg-config,
|
|
openssl,
|
|
stdenv,
|
|
curl,
|
|
versionCheckHook,
|
|
nix-update-script,
|
|
}:
|
|
|
|
rustPlatform.buildRustPackage (finalAttrs: {
|
|
pname = "cargo-tarpaulin";
|
|
version = "0.36.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "xd009642";
|
|
repo = "tarpaulin";
|
|
tag = finalAttrs.version;
|
|
hash = "sha256-qd0PmCCUmd9Y4kUei+hZoc+rIYYZMf0s2ml9IoHtXX8=";
|
|
};
|
|
|
|
cargoHash = "sha256-EJTzITwwLEMVWdLdSE+A9D3Deh501561rxrlsqzmRKs=";
|
|
|
|
nativeBuildInputs = [
|
|
pkg-config
|
|
];
|
|
buildInputs = [
|
|
openssl
|
|
]
|
|
++ lib.optionals stdenv.hostPlatform.isDarwin [
|
|
curl
|
|
];
|
|
|
|
doCheck = false;
|
|
|
|
doInstallCheck = true;
|
|
nativeInstallCheckInputs = [ versionCheckHook ];
|
|
versionCheckProgramArg = "--version";
|
|
|
|
passthru.updateScript = nix-update-script { };
|
|
|
|
meta = {
|
|
description = "Code coverage tool for Rust projects";
|
|
mainProgram = "cargo-tarpaulin";
|
|
homepage = "https://github.com/xd009642/tarpaulin";
|
|
changelog = "https://github.com/xd009642/tarpaulin/blob/${finalAttrs.version}/CHANGELOG.md";
|
|
license = with lib.licenses; [
|
|
mit # or
|
|
asl20
|
|
];
|
|
maintainers = with lib.maintainers; [
|
|
hugoreeves
|
|
progrm_jarvis
|
|
];
|
|
};
|
|
})
|