vend: init at unstable-2020-06-04
This is used to provide alternate vendoring for go.
This commit is contained in:
parent
56c86e7ce7
commit
148138e9de
26
pkgs/development/tools/vend/default.nix
Normal file
26
pkgs/development/tools/vend/default.nix
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
{ stdenv, buildGoModule, fetchFromGitHub }:
|
||||||
|
|
||||||
|
buildGoModule {
|
||||||
|
pname = "vend";
|
||||||
|
version = "unstable-2020-06-04";
|
||||||
|
|
||||||
|
patches = [./remove_tidy.patch];
|
||||||
|
|
||||||
|
# A permanent fork from master is maintained to avoid non deterministic go tidy
|
||||||
|
src = fetchFromGitHub {
|
||||||
|
owner = "c00w";
|
||||||
|
repo = "vend";
|
||||||
|
rev = "24fdebfdb2c3cc0516321a9cf33a3fd81c209c04";
|
||||||
|
sha256 = "112p9dz9by2h2m3jha2bv1bvzn2a86bpg1wphgmf9gksjpwy835l";
|
||||||
|
};
|
||||||
|
|
||||||
|
vendorSha256 = null;
|
||||||
|
|
||||||
|
meta = with stdenv.lib; {
|
||||||
|
homepage = "https://github.com/c00w/vend";
|
||||||
|
description = "A utility which vendors go code including c dependencies";
|
||||||
|
maintainers = with maintainers; [ c00w ];
|
||||||
|
license = licenses.mit;
|
||||||
|
platforms = platforms.all;
|
||||||
|
};
|
||||||
|
}
|
13
pkgs/development/tools/vend/remove_tidy.patch
Normal file
13
pkgs/development/tools/vend/remove_tidy.patch
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
diff --git a/cli/cmd.go b/cli/cmd.go
|
||||||
|
index c766559..3a133fd 100644
|
||||||
|
--- a/cli/cmd.go
|
||||||
|
+++ b/cli/cmd.go
|
||||||
|
@@ -12,7 +12,7 @@ import (
|
||||||
|
// UpdateModule makes sure the module is updated ready to vendor the
|
||||||
|
// dependencies.
|
||||||
|
func UpdateModule() {
|
||||||
|
- var commands = []string{"tidy", "download", "vendor"}
|
||||||
|
+ var commands = []string{"download", "vendor"}
|
||||||
|
|
||||||
|
for _, command := range commands {
|
||||||
|
cmd := exec.Command("go", "mod", command)
|
Loading…
Reference in New Issue
Block a user