summary refs log tree commit diff
path: root/pkgs/development/tools/misc/hound/default.nix
blob: 2d7431f9e8b0815460608e29f9e3518f72a2818f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
{ stdenv
, buildGoPackage
, fetchFromGitHub
, makeWrapper
, mercurial
, git
}:

buildGoPackage rec {
  pname = "hound-unstable";
  version = "2018-11-02";
  rev = "74ec7448a234d8d09e800b92e52c92e378c07742";

  nativeBuildInputs = [ makeWrapper ];

  goPackagePath = "github.com/etsy/hound";

  src = fetchFromGitHub {
    inherit rev;
    owner = "etsy";
    repo = "hound";
    sha256 = "0g6nvgqjabprcl9z5ci5frhbam1dzq978h1d6aanf8vvzslfgdpq";
  };

  goDeps = ./deps.nix;

  postInstall = with stdenv; let
    binPath = lib.makeBinPath [ mercurial git ];
  in ''
    wrapProgram $out/bin/houndd --prefix PATH : ${binPath}
  '';

  meta = {
    inherit (src.meta) homepage;

    description = "Lightning fast code searching made easy";
    license = stdenv.lib.licenses.mit;
    maintainers = with stdenv.lib.maintainers; [ grahamc ];
    platforms = stdenv.lib.platforms.unix;
  };
}