2022-03-05 16:20:37 +00:00
|
|
|
{ lib
|
|
|
|
, rustPlatform
|
|
|
|
, fetchFromGitHub
|
|
|
|
, stdenv
|
|
|
|
, Security
|
2022-04-27 09:35:20 +00:00
|
|
|
, testers
|
2022-03-05 16:20:37 +00:00
|
|
|
, igrep
|
|
|
|
}:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "igrep";
|
2022-04-27 09:35:20 +00:00
|
|
|
version = "0.5.0";
|
2022-03-05 16:20:37 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "konradsz";
|
|
|
|
repo = "igrep";
|
|
|
|
rev = "v${version}";
|
2022-04-27 09:35:20 +00:00
|
|
|
sha256 = "sha256-mJtxqwbqofiDuiGokn24qdnck27w7w/3A5mdqZIU88U=";
|
2022-03-05 16:20:37 +00:00
|
|
|
};
|
|
|
|
|
2022-04-27 09:35:20 +00:00
|
|
|
cargoSha256 = "sha256-ikU4SRLu7PQGbidPmf2W39e3sE8QY8YMU6Q0eWhgvLM=";
|
2022-03-05 16:20:37 +00:00
|
|
|
|
|
|
|
buildInputs = lib.optionals stdenv.isDarwin [ Security ];
|
|
|
|
|
|
|
|
passthru.tests = {
|
2022-04-27 09:35:20 +00:00
|
|
|
version = testers.testVersion { package = igrep; command = "ig --version"; };
|
2022-03-05 16:20:37 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Interactive Grep";
|
|
|
|
homepage = "https://github.com/konradsz/igrep";
|
2022-03-10 19:12:11 +00:00
|
|
|
changelog = "https://github.com/konradsz/igrep/blob/v${version}/CHANGELOG.md";
|
2022-03-05 16:20:37 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ _0x4A6F ];
|
2022-04-27 09:35:20 +00:00
|
|
|
mainProgram = "ig";
|
2022-03-05 16:20:37 +00:00
|
|
|
};
|
|
|
|
}
|