3
0
Fork 0
forked from mirrors/nixpkgs

Merge pull request #5750 from rycee/issue/5741

Wrap 'tig' command to add with git to PATH.
This commit is contained in:
lethalman 2015-01-28 14:52:45 +01:00
commit 2140080b08
2 changed files with 8 additions and 5 deletions

View file

@ -68,9 +68,7 @@ rec {
inherit stdenv fetchurl;
};
tig = import ./tig {
inherit stdenv fetchurl ncurses asciidoc xmlto docbook_xsl docbook_xml_dtd_45 readline;
};
tig = callPackage ./tig { };
hub = import ./hub {
inherit go;

View file

@ -1,5 +1,5 @@
{ stdenv, fetchurl, ncurses, asciidoc, xmlto, docbook_xsl, docbook_xml_dtd_45
, readline
, readline, makeWrapper, git
}:
stdenv.mkDerivation rec {
@ -11,17 +11,22 @@ stdenv.mkDerivation rec {
};
buildInputs = [ ncurses asciidoc xmlto docbook_xsl readline ];
buildInputs = [ ncurses asciidoc xmlto docbook_xsl readline git makeWrapper ];
preConfigure = ''
export XML_CATALOG_FILES='${docbook_xsl}/xml/xsl/docbook/catalog.xml ${docbook_xml_dtd_45}/xml/dtd/docbook/catalog.xml'
'';
enableParallelBuilding = true;
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"
'';
meta = with stdenv.lib; {