2021-09-22 15:38:15 +00:00
|
|
|
{ lib
|
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
2021-12-06 16:07:01 +00:00
|
|
|
, stdenv
|
|
|
|
, Security
|
2023-11-16 04:20:00 +00:00
|
|
|
, SystemConfiguration
|
2021-09-22 15:38:15 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "cargo-spellcheck";
|
2024-01-13 08:15:51 +00:00
|
|
|
version = "0.13.2";
|
2021-09-22 15:38:15 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "drahnr";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2024-01-13 08:15:51 +00:00
|
|
|
hash = "sha256-PgV+sjCf4O24v0i9P7RJIcn28OWMUcPSwy+P5n8RwS4=";
|
2021-09-22 15:38:15 +00:00
|
|
|
};
|
|
|
|
|
2024-01-13 08:15:51 +00:00
|
|
|
cargoHash = "sha256-6dhM+FzuLtKtRp2mpE9nlpT+0PBcgGqvBa9vqs6Rs7s=";
|
2021-09-22 15:38:15 +00:00
|
|
|
|
2023-07-15 17:15:38 +00:00
|
|
|
nativeBuildInputs = [ rustPlatform.bindgenHook ];
|
2021-12-06 16:07:01 +00:00
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
buildInputs = lib.optionals stdenv.isDarwin [ Security SystemConfiguration ];
|
2021-09-22 15:38:15 +00:00
|
|
|
|
2021-12-30 13:39:12 +00:00
|
|
|
preCheck = "HOME=$(mktemp -d)";
|
|
|
|
|
2021-09-22 15:38:15 +00:00
|
|
|
checkFlags = [
|
|
|
|
"--skip checker::hunspell::tests::hunspell_binding_is_sane"
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Checks rust documentation for spelling and grammar mistakes";
|
|
|
|
homepage = "https://github.com/drahnr/cargo-spellcheck";
|
2022-02-10 20:34:41 +00:00
|
|
|
changelog = "https://github.com/drahnr/cargo-spellcheck/blob/v${version}/CHANGELOG.md";
|
2021-09-22 15:38:15 +00:00
|
|
|
license = with licenses; [ asl20 /* or */ mit ];
|
2023-08-22 20:05:09 +00:00
|
|
|
maintainers = with maintainers; [ newam matthiasbeyer ];
|
2021-09-22 15:38:15 +00:00
|
|
|
};
|
|
|
|
}
|