2021-01-11 07:54:33 +00:00
|
|
|
{ lib, stdenv
|
2019-03-30 22:55:12 +00:00
|
|
|
, fetchFromGitHub
|
|
|
|
, coreutils
|
|
|
|
, sharutils
|
2021-09-18 05:15:44 +00:00
|
|
|
, runtimeShell
|
2019-03-30 22:55:12 +00:00
|
|
|
, version
|
|
|
|
, sha256
|
|
|
|
}:
|
|
|
|
|
2019-08-13 21:52:01 +00:00
|
|
|
stdenv.mkDerivation {
|
2019-03-30 22:55:12 +00:00
|
|
|
inherit version;
|
2019-08-15 12:41:18 +00:00
|
|
|
pname = "vimpager";
|
2019-03-30 22:55:12 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
inherit sha256;
|
|
|
|
|
|
|
|
owner = "rkitover";
|
|
|
|
repo = "vimpager";
|
2019-09-08 23:38:31 +00:00
|
|
|
rev = version;
|
2019-03-30 22:55:12 +00:00
|
|
|
};
|
|
|
|
|
2021-09-17 19:50:21 +00:00
|
|
|
nativeBuildInputs = [ sharutils ]; # for uuencode
|
|
|
|
buildInputs = [ coreutils ];
|
2019-03-30 22:55:12 +00:00
|
|
|
|
|
|
|
makeFlags = [
|
|
|
|
"PREFIX=$(out)"
|
|
|
|
];
|
|
|
|
|
|
|
|
buildPhase = ''
|
|
|
|
sed -i 's,/bin/cat,${coreutils}/bin/cat,g' vimpager
|
|
|
|
make
|
|
|
|
'';
|
|
|
|
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2019-03-30 22:55:12 +00:00
|
|
|
description = "Use Vim as PAGER";
|
2019-11-06 18:59:17 +00:00
|
|
|
homepage = "https://www.vim.org/scripts/script.php?script_id=1723";
|
2019-03-30 22:55:12 +00:00
|
|
|
license = with licenses; [ bsd2 mit vim ];
|
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
|
|
|
}
|