riffdiff: use best practices

This commit is contained in:
seth 2024-11-01 13:03:44 -04:00
parent 49872f3ca6
commit 67dee65a87
No known key found for this signature in database
GPG Key ID: D31BD0D494BBEE86

View File

@ -2,6 +2,9 @@
lib,
rustPlatform,
fetchFromGitHub,
nix-update-script,
riffdiff,
testers,
}:
rustPlatform.buildRustPackage rec {
@ -11,17 +14,23 @@ rustPlatform.buildRustPackage rec {
src = fetchFromGitHub {
owner = "walles";
repo = "riff";
rev = version;
rev = "refs/tags/${version}";
hash = "sha256-IdYQ8vD3ZIzqdNY4JtR8f2huV/DWOhV8FUn7tuRe7IQ=";
};
cargoHash = "sha256-1on4CTstEvjNLtk1RG6dcNl0XhaPYAy+U0DYn/aVzEg=";
meta = with lib; {
passthru = {
tests.version = testers.testVersion { package = riffdiff; };
updateScript = nix-update-script { };
};
meta = {
description = "Diff filter highlighting which line parts have changed";
homepage = "https://github.com/walles/riff";
license = licenses.mit;
maintainers = with maintainers; [ johnpyp ];
changelog = "https://github.com/walles/riff/releases/tag/${version}";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ johnpyp ];
mainProgram = "riff";
};
}