2022-09-09 14:08:57 +00:00
|
|
|
{ lib
|
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
|
|
|
, pkg-config
|
|
|
|
, libgit2
|
|
|
|
, openssl
|
|
|
|
, stdenv
|
|
|
|
, Security
|
|
|
|
}:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "cargo-semver-checks";
|
2022-09-30 11:47:45 +00:00
|
|
|
version = "0.12.0";
|
2022-09-09 14:08:57 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "obi1kenobi";
|
|
|
|
repo = "cargo-semver-check";
|
|
|
|
rev = "v${version}";
|
2022-09-30 11:47:45 +00:00
|
|
|
sha256 = "sha256-gB8W/u/Yb/rMMB+654N3Mj4QbTMWGK6cgQKM0lld/10=";
|
2022-09-09 14:08:57 +00:00
|
|
|
};
|
|
|
|
|
2022-09-30 11:47:45 +00:00
|
|
|
cargoSha256 = "sha256-ML4cTNtCvaLFkt1QdA34QvAGhrFTO90xw7fsUD2weqQ=";
|
2022-09-09 14:08:57 +00:00
|
|
|
|
|
|
|
nativeBuildInputs = [ pkg-config ];
|
|
|
|
|
|
|
|
buildInputs = [ libgit2 openssl ] ++ lib.optionals stdenv.isDarwin [
|
|
|
|
Security
|
|
|
|
];
|
|
|
|
|
|
|
|
checkFlags = [
|
|
|
|
# requires nightly version of cargo-rustdoc
|
|
|
|
"--skip=adapter::tests"
|
2022-09-30 11:47:45 +00:00
|
|
|
"--skip=query::tests"
|
2022-09-09 14:08:57 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A tool to scan your Rust crate for semver violations";
|
|
|
|
homepage = "https://github.com/obi1kenobi/cargo-semver-check";
|
|
|
|
license = licenses.asl20;
|
2022-09-30 11:47:45 +00:00
|
|
|
maintainers = with maintainers; [ figsoda matthiasbeyer ];
|
2022-09-09 14:08:57 +00:00
|
|
|
};
|
|
|
|
}
|