nixpkgs/pkgs/applications/version-management/git-and-tools/tig/default.nix

49 lines
1.3 KiB
Nix
Raw Normal View History

{ stdenv, fetchFromGitHub, ncurses, asciidoc, xmlto, docbook_xsl, docbook_xml_dtd_45
2017-05-07 23:22:29 +02:00
, readline, makeWrapper, git, libiconv, autoreconfHook, findXMLCatalogs, pkgconfig
}:
2012-08-08 00:49:12 +02:00
2012-11-17 02:13:25 +01:00
stdenv.mkDerivation rec {
pname = "tig";
2018-02-25 12:24:35 +01:00
version = "2.3.3";
name = "${pname}-${version}";
src = fetchFromGitHub {
owner = "jonas";
repo = pname;
rev = name;
2018-02-25 12:24:35 +01:00
sha256 = "1gw5ia6cl5b0q91kv4vfg35my2p49np23aikxqf5gn00zhqrkfap";
2012-08-08 00:49:12 +02:00
};
2017-05-07 23:22:29 +02:00
nativeBuildInputs = [ makeWrapper autoreconfHook asciidoc xmlto docbook_xsl docbook_xml_dtd_45 findXMLCatalogs pkgconfig ];
autoreconfFlags = "-I tools -v";
buildInputs = [ ncurses readline git ]
2015-11-07 13:50:25 +01:00
++ stdenv.lib.optionals stdenv.isDarwin [ libiconv ];
# those files are inherently impure, we'll handle the corresponding dependencies.
postPatch = ''
rm -f contrib/config.make-*
'';
enableParallelBuilding = true;
2012-08-08 00:49:12 +02:00
installPhase = ''
make install
make install-doc
mkdir -p $out/etc/bash_completion.d/
cp contrib/tig-completion.bash $out/etc/bash_completion.d/
wrapProgram $out/bin/tig \
--prefix PATH ':' "${git}/bin"
2012-08-08 00:49:12 +02:00
'';
meta = with stdenv.lib; {
homepage = https://jonas.github.io/tig/;
description = "Text-mode interface for git";
maintainers = with maintainers; [ garbas bjornfor domenkozar qknight ];
license = licenses.gpl2;
platforms = platforms.unix;
2012-08-08 00:49:12 +02:00
};
}