2021-01-15 22:18:51 +00:00
|
|
|
{ lib, stdenv
|
2020-10-16 20:44:37 +00:00
|
|
|
, fetchFromGitHub
|
|
|
|
, rustPlatform
|
2021-02-13 14:23:35 +00:00
|
|
|
, Security
|
2020-10-16 20:44:37 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "grex";
|
2023-08-04 22:07:22 +00:00
|
|
|
version = "1.4.2";
|
2020-10-16 20:44:37 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "pemistahl";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2023-08-04 22:07:22 +00:00
|
|
|
sha256 = "sha256-kbrBnpoVeXSgmIqElpfAnoSutYwsnFaxFJpRsJPUE8k=";
|
2020-10-16 20:44:37 +00:00
|
|
|
};
|
|
|
|
|
2023-08-04 22:07:22 +00:00
|
|
|
cargoSha256 = "sha256-WO8h5JUEiCpfsROQoRZj7I6em6REcJ2PfmoGN1zKRPg=";
|
2022-08-12 12:06:08 +00:00
|
|
|
|
2021-02-13 14:23:35 +00:00
|
|
|
buildInputs = lib.optionals stdenv.isDarwin [ Security ];
|
2020-10-16 20:44:37 +00:00
|
|
|
|
|
|
|
doInstallCheck = true;
|
|
|
|
installCheckPhase = ''
|
|
|
|
$out/bin/grex --help > /dev/null
|
|
|
|
'';
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-10-16 20:44:37 +00:00
|
|
|
description = "A command-line tool for generating regular expressions from user-provided test cases";
|
|
|
|
homepage = "https://github.com/pemistahl/grex";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ SuperSandro2000 ];
|
|
|
|
};
|
|
|
|
}
|