2022-07-08 11:53:39 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitHub
|
|
|
|
, unixtools
|
|
|
|
, which
|
|
|
|
}:
|
2014-11-25 21:40:25 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 12:41:18 +00:00
|
|
|
pname = "git-extras";
|
2023-04-30 02:47:43 +00:00
|
|
|
version = "7.0.0";
|
2014-11-25 21:40:25 +00:00
|
|
|
|
2021-02-12 03:17:31 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "tj";
|
|
|
|
repo = "git-extras";
|
|
|
|
rev = version;
|
2023-04-30 02:47:43 +00:00
|
|
|
sha256 = "sha256-BoTMaM/6F/vXn9y80baYnP9z0PwgnJrk9inYt0JIb+Q=";
|
2014-11-25 21:40:25 +00:00
|
|
|
};
|
|
|
|
|
2021-09-28 15:57:29 +00:00
|
|
|
postPatch = ''
|
|
|
|
patchShebangs check_dependencies.sh
|
|
|
|
'';
|
2019-11-12 18:14:34 +00:00
|
|
|
|
2021-09-28 15:57:29 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
unixtools.column
|
|
|
|
which
|
|
|
|
];
|
2014-11-25 21:40:25 +00:00
|
|
|
|
2021-09-28 15:57:29 +00:00
|
|
|
dontBuild = true;
|
2019-11-12 18:14:34 +00:00
|
|
|
|
2021-09-28 15:57:29 +00:00
|
|
|
installFlags = [
|
|
|
|
"PREFIX=${placeholder "out"}"
|
|
|
|
"SYSCONFDIR=${placeholder "out"}/share"
|
|
|
|
];
|
2014-11-25 21:40:25 +00:00
|
|
|
|
2018-09-11 09:48:19 +00:00
|
|
|
postInstall = ''
|
2019-11-12 18:14:34 +00:00
|
|
|
# bash completion is already handled by make install
|
2018-09-11 09:48:19 +00:00
|
|
|
install -D etc/git-extras-completion.zsh $out/share/zsh/site-functions/_git_extras
|
|
|
|
'';
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2020-04-01 01:11:51 +00:00
|
|
|
homepage = "https://github.com/tj/git-extras";
|
2014-11-25 21:40:25 +00:00
|
|
|
description = "GIT utilities -- repo summary, repl, changelog population, author commit percentages and more";
|
|
|
|
license = licenses.mit;
|
|
|
|
platforms = platforms.all;
|
2023-05-05 12:34:05 +00:00
|
|
|
maintainers = with maintainers; [ cko SuperSandro2000 ];
|
2014-11-25 21:40:25 +00:00
|
|
|
};
|
|
|
|
}
|