2020-11-03 02:18:15 +00:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub, go-md2man, installShellFiles }:
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "vgrep";
|
2021-12-06 16:07:01 +00:00
|
|
|
version = "2.5.5";
|
2020-09-25 04:45:31 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "vrothberg";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2021-12-06 16:07:01 +00:00
|
|
|
sha256 = "sha256-pWRc1EjL09zFT/8HLrosuCJ5qTDj2VaizoI/Eu8jsgM=";
|
2020-09-25 04:45:31 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
vendorSha256 = null;
|
|
|
|
|
2021-08-06 21:57:35 +00:00
|
|
|
ldflags = [ "-s" "-w" "-X main.version=${version}" ];
|
2020-09-25 04:45:31 +00:00
|
|
|
|
2020-11-03 02:18:15 +00:00
|
|
|
nativeBuildInputs = [ go-md2man installShellFiles ];
|
|
|
|
|
|
|
|
postBuild = ''
|
|
|
|
sed -i '/SHELL= /d' Makefile
|
|
|
|
make docs
|
|
|
|
installManPage docs/*.[1-9]
|
|
|
|
'';
|
|
|
|
|
2020-09-25 04:45:31 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "User-friendly pager for grep/git-grep/ripgrep";
|
|
|
|
homepage = "https://github.com/vrothberg/vgrep";
|
|
|
|
license = licenses.gpl3Only;
|
2021-06-28 23:13:55 +00:00
|
|
|
maintainers = with maintainers; [ SuperSandro2000 ];
|
2020-09-25 04:45:31 +00:00
|
|
|
};
|
|
|
|
}
|