Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)

Add godep, dependency tool for go

+91
+30
pkgs/development/tools/godep/default.nix
··· 1 + { stdenv, lib, go, fetchurl, fetchgit, fetchhg, fetchbzr, fetchFromGitHub }: 2 + 3 + stdenv.mkDerivation rec { 4 + version = "ddd7fbf"; 5 + name = "godep-${version}"; 6 + 7 + src = import ./deps.nix { 8 + inherit stdenv lib fetchgit fetchFromGitHub; 9 + }; 10 + 11 + buildInputs = [ go ]; 12 + 13 + buildPhase = '' 14 + export GOPATH=$src 15 + go build -v -o godep github.com/tools/godep 16 + ''; 17 + 18 + installPhase = '' 19 + mkdir -p $out/bin 20 + mv godep $out/bin 21 + ''; 22 + 23 + meta = with stdenv.lib; { 24 + description = "Ddependency tool for go"; 25 + homepage = https://github.com/tools/godep; 26 + license = licenses.bsd3; 27 + maintainers = with maintainers; [ offline ]; 28 + platforms = platforms.unix; 29 + }; 30 + }
+59
pkgs/development/tools/godep/deps.nix
··· 1 + # This file was generated by go2nix. 2 + { stdenv, lib, fetchFromGitHub, fetchgit }: 3 + 4 + let 5 + goDeps = [ 6 + { 7 + root = "github.com/kr/fs"; 8 + src = fetchgit { 9 + url = "https://github.com/kr/fs.git"; 10 + rev = "2788f0dbd16903de03cb8186e5c7d97b69ad387b"; 11 + sha256 = "1c0fipl4rsh0v5liq1ska1dl83v3llab4k6lm8mvrx9c4dyp71ly"; 12 + }; 13 + } 14 + { 15 + root = "github.com/tools/godep"; 16 + src = fetchgit { 17 + url = "https://github.com/tools/godep.git"; 18 + rev = "0baa7ea464025b2cb8e84b13c5ac4da99237a1bf"; 19 + sha256 = "10hr10fj6ymmfzwjg5drf7j0f4mrpb4p97a01rqp7xvfv5j0zisj"; 20 + }; 21 + } 22 + { 23 + root = "golang.org/x/net"; 24 + src = fetchgit { 25 + url = "https://go.googlesource.com/net"; 26 + rev = "8b2d0ae1f4c3b83c10ff17e89a89ff04cc0903c3"; 27 + sha256 = "0nxawxhq7yysbrrd88hkqzfr5hvsqpd452yzi53cp1afzma3zjay"; 28 + }; 29 + } 30 + { 31 + root = "golang.org/x/text"; 32 + src = fetchgit { 33 + url = "https://go.googlesource.com/text"; 34 + rev = "bfad311ce93436dc888b40d76c78f99dc3104473"; 35 + sha256 = "1mbhp5q24drz2l2x6ib3180i42f9015ry80bn7jhr7rwizvyp6lh"; 36 + }; 37 + } 38 + { 39 + root = "golang.org/x/tools"; 40 + src = fetchgit { 41 + url = "https://go.googlesource.com/tools"; 42 + rev = "3ecc311976cc3f7c7b7a50314929bdc1b07c4c9d"; 43 + sha256 = "0ic3lrg6ykxrlnzcway4ka280n052qysjawf4lvj8gl3r1vlmwfg"; 44 + }; 45 + } 46 + ]; 47 + 48 + in 49 + 50 + stdenv.mkDerivation rec { 51 + name = "go-deps"; 52 + 53 + buildCommand = 54 + lib.concatStrings 55 + (map (dep: '' 56 + mkdir -p $out/src/`dirname ${dep.root}` 57 + ln -s ${dep.src} $out/src/${dep.root} 58 + '') goDeps); 59 + }
+2
pkgs/top-level/all-packages.nix
··· 8804 8804 8805 8805 golint = callPackage ../development/tools/golint { }; 8806 8806 8807 + godep = callPackage ../development/tools/godep { }; 8808 + 8807 8809 gogoclient = callPackage ../os-specific/linux/gogoclient { }; 8808 8810 8809 8811 nss_ldap = callPackage ../os-specific/linux/nss_ldap { };