gitAndTools.hub: 2.7.0 -> 2.9.0

We need to add git to PATH to build the manual
as they execute `hub version | tail -1` to get the version
to embed into it.

Though git is really only needed because it runs `git version`
as well.
This commit is contained in:
worldofpeace 2019-02-17 11:54:29 -05:00
parent 4bf34f16d8
commit 96ac29b2e0

@ -1,25 +1,26 @@
{ stdenv, buildGoPackage, fetchFromGitHub, ronn, ruby, groff, Security, utillinux }: { stdenv, buildGoPackage, fetchFromGitHub, ronn, ruby, groff, Security, utillinux, git, glibcLocales }:
buildGoPackage rec { buildGoPackage rec {
name = "hub-${version}"; pname = "hub";
version = "2.7.0"; version = "2.9.0";
goPackagePath = "github.com/github/hub"; goPackagePath = "github.com/github/hub";
# Only needed to build the man-pages
excludedPackages = [ "github.com/github/hub/md2roff-bin" ];
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "github"; owner = "github";
repo = "hub"; repo = pname;
rev = "v${version}"; rev = "v${version}";
sha256 = "1p90m1xp3jahs5y0lp0qfmfa7wqn7gxyygn7x45a6cbf2zzlb86l"; sha256 = "0yxpr606xx23l8823hjqj16cvjjrwb28c7z08ml1pkfvaf7w4n81";
}; };
nativeBuildInputs = [ groff ronn utillinux ]; nativeBuildInputs = [ groff ronn utillinux glibcLocales ];
buildInputs = [ ruby ] ++ buildInputs = [ ruby ] ++
stdenv.lib.optional stdenv.isDarwin Security; stdenv.lib.optional stdenv.isDarwin Security;
postPatch = '' postPatch = ''
mkdir bin
ln -s ${ronn}/bin/ronn bin/ronn
patchShebangs . patchShebangs .
''; '';
@ -29,13 +30,12 @@ buildGoPackage rec {
install -D etc/hub.bash_completion.sh "$bin/share/bash-completion/completions/hub" install -D etc/hub.bash_completion.sh "$bin/share/bash-completion/completions/hub"
install -D etc/hub.fish_completion "$bin/share/fish/vendor_completions.d/hub.fish" install -D etc/hub.fish_completion "$bin/share/fish/vendor_completions.d/hub.fish"
make man-pages PATH=$PATH:${git}/bin LC_ALL=en_US.utf-8 make man-pages
cp -vr --parents share/man/man[1-9]/*.[1-9] $bin/ cp -vr --parents share/man/man[1-9]/*.[1-9] $bin/
''; '';
meta = with stdenv.lib; { meta = with stdenv.lib; {
description = "Command-line wrapper for git that makes you better at GitHub"; description = "Command-line wrapper for git that makes you better at GitHub";
license = licenses.mit; license = licenses.mit;
homepage = https://hub.github.com/; homepage = https://hub.github.com/;
maintainers = with maintainers; [ the-kenny ]; maintainers = with maintainers; [ the-kenny ];