Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib, stdenv, fetchFromGitHub, rustPlatform, Security }: 2 3rustPlatform.buildRustPackage rec { 4 pname = "diffr"; 5 version = "0.1.5"; 6 7 src = fetchFromGitHub { 8 owner = "mookid"; 9 repo = pname; 10 rev = "v${version}"; 11 sha256 = "sha256-ylZE2NtTXbGqsxE72ylEQCacTyxBO+/WgvEpoXd5OZI="; 12 }; 13 14 cargoHash = "sha256-RmQu55OnKfeuDGcJrfjhMKnxDatdowkvh3Kh4N8I8Sg="; 15 16 buildInputs = (lib.optional stdenv.isDarwin Security); 17 18 preCheck = '' 19 export DIFFR_TESTS_BINARY_PATH=$releaseDir/diffr 20 ''; 21 22 meta = with lib; { 23 description = "Yet another diff highlighting tool"; 24 homepage = "https://github.com/mookid/diffr"; 25 license = with licenses; [ mit ]; 26 maintainers = with maintainers; [ davidtwco ]; 27 }; 28}