summary refs log tree commit diff
path: root/pkgs/development/tools/gotags/deps.nix
blob: 97e77bdd977e25d008f72bce5b5ad33173c931bb (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
{ stdenv, lib, fetchgit, fetchhg, fetchbzr, fetchFromGitHub }:

let
  goDeps = [
    {
      root = "github.com/jstemmer/gotags";
      src = fetchFromGitHub {
        owner = "jstemmer";
        repo = "gotags";
        rev = "a60c6a1b171faedc44354bd437d965e5e3bdc220";
        sha256 = "1drbypby0isdmkq44jmlv59k3jrwvq2jciaccxx2qc2nnx444fkq";
      };
    }
  ];

in

stdenv.mkDerivation rec {
  name = "go-deps";

  buildCommand =
    lib.concatStrings
      (map (dep: ''
              mkdir -p $out/src/`dirname ${dep.root}`
              ln -s ${dep.src} $out/src/${dep.root}
            '') goDeps);
}