depot/third_party/nixpkgs/pkgs/tools/misc/grex/default.nix
Default email 5e9e1146e1 Project import generated by Copybara.
GitOrigin-RevId: 18036c0be90f4e308ae3ebcab0e14aae0336fe42
2023-08-05 00:07:22 +02:00

33 lines
806 B
Nix

{ lib, stdenv
, fetchFromGitHub
, rustPlatform
, Security
}:
rustPlatform.buildRustPackage rec {
pname = "grex";
version = "1.4.2";
src = fetchFromGitHub {
owner = "pemistahl";
repo = pname;
rev = "v${version}";
sha256 = "sha256-kbrBnpoVeXSgmIqElpfAnoSutYwsnFaxFJpRsJPUE8k=";
};
cargoSha256 = "sha256-WO8h5JUEiCpfsROQoRZj7I6em6REcJ2PfmoGN1zKRPg=";
buildInputs = lib.optionals stdenv.isDarwin [ Security ];
doInstallCheck = true;
installCheckPhase = ''
$out/bin/grex --help > /dev/null
'';
meta = with lib; {
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 ];
};
}