GithubHelp home page GithubHelp logo

vndr's Introduction

VNDR

Build Status

Vndr is simple vendoring tool, which is inspired by Docker vendor script. Vndr has next command line arguments:

  • -verbose adds additional output, helpful for debugging issues.
  • -whitelist allows you to specify several regular expressions for paths which will not be cleaned in the final stage of vendoring -- this is useful for running tests in a vendored project or otherwise ensuring that some important files are retained after vndr is done cleaning unused files from your vendor/ directory.
  • -strict exits with non-zero status on non-trivial warning

Installation

Execute

go get github.com/LK4D4/vndr

vendor.conf

vendor.conf is the configuration file of vndr. It must have multiple lines, which have format:

Import path               | revision                               | Repository(optional)
github.com/example/example 03a4d9dcf2f92eae8e90ed42aa2656f63fdd0b14 https://github.com/LK4D4/example.git

You can use Repository field for vendoring forks instead of original repos. This config format is also accepted by trash.

Initialization

You can initiate your project with vendor directory and vendor.conf using command vndr init. This will populate your vendor directory with latest versions of all dependencies and also write vendor.conf config which you can use for changing versions later.

Updating or using existing vendor.conf

If you already have vendor.conf you can just change versions there as you like, set $GOPATH and run vndr in your repository with that file:

vndr

(Note: Your repository must be in proper place in $GOPATH, i.e. $GOPATH/src/github.com/LK4D4/vndr).

Also it's possible to vendor or update only one dependency:

vndr github.com/example/example 03a4d9dcf2f92eae8e90ed42aa2656f63fdd0b14 https://github.com/LK4D4/example.git

or

vndr github.com/example/example

to take revision and repo from vendor.conf.

If you experience any problems, please try to run vndr -verbose.

Sometimes vndr might suggest you to change your vendor.conf:

  • in case of duplicated or non-top packages it will write suggested file to vendor.conf.tmp, you should diff your file with it and make changes accordingly.
  • in case of unused packages it will just print warning

vndr's People

Contributors

akihirosuda avatar aleksi avatar carlosedp avatar crosbymichael avatar cyphar avatar dqminh avatar golint-fixer avatar ijc avatar lelenanam avatar lk4d4 avatar michaldarda avatar mrjana avatar quasilyte avatar tbble avatar thajeztah avatar xulike666 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

vndr's Issues

vndr deletes vendor files needed by golang code

From the docker repo, running vndr ends up with many files deleted from vendor dir which are needed at compile time:

$ git clone https://github.com/docker/docker.git && cd docker
$ go get github.com/LK4D4/vndr
$ vndr # usually fails on first try with ssl error
...
2016/12/27 16:21:50 	Finished clone google.golang.org/api
2016/12/27 16:21:50 Errors on clone:
golang.org/x/sys: Err: exit status 128, out: Cloning into '/Users/andrewhsu/work/src/github.com/docker/docker/vendor/golang.org/x/sys'...
fatal: unable to access 'https://go.googlesource.com/sys/': Server aborted the SSL handshake

golang.org/x/crypto: Err: exit status 128, out: Cloning into '/Users/andrewhsu/work/src/github.com/docker/docker/vendor/golang.org/x/crypto'...
fatal: unable to access 'https://go.googlesource.com/crypto/': Server aborted the SSL handshake

google.golang.org/cloud: Err: exit status 128, out: Cloning into '/Users/andrewhsu/work/src/github.com/docker/docker/vendor/google.golang.org/cloud'...
fatal: unable to access 'https://code.googlesource.com/gocloud/': Server aborted the SSL handshake
$ vndr # second try usually succeeds
$ git status | grep deleted | wc -l # count deleted files
     221

Warn about unused packages listed in vendor.conf

Typically the complete dependency tree needs to be flattened into vendor.conf, so if you vendor package pkga and it depends on pkgb you have both pkga and pkgb listed. If you then update to a newer version of pkga which no longer requires pkgb then you might not notice and remember to remove pkgb from vendor.conf.

It would be useful if vndr would warn when it noticed that it had garbage collected something explicitly listed in vendor.conf during cleanVendor.

It's also possible that I might remove the last usage of pkga in my code without noticing, this would highlight that too (but only if you happen to run vndr).

Vendoring standard packages

Sometimes a standard package from a particular Go release introduces a regression which can be fixed by using a modified copy of it. So, it would be nice to have an ability to vendor forks of standard packages. Something like this (an entry in vendor.conf:

archive/tar go-1.10 https://github.com:kolyshkin/go-tar.git

Currently, vndr complains:

2018/06/08 18:09:04 unrecognized import path "archive/tar" (import path does not begin with hostname)

so I had to vendor this manually, i.e.

mkdir -p vendor/archive
git clone -b go-1.10 --depth=1 [email protected]:kolyshkin/go-tar.git ./vendor/archive/tar

Now the code that does import "archive/tar" works with my own version of archive/tar, without a need to change the import statements in a bazillion places.

It would be awesome to achieve the same thing by using vndr and avoiding manual steps.

Gory details

You probably don't want to know. In case you do:

Infinite loop when an invalid version/tag is defined

Feel free to close this with "don't define invalid tags" ๐Ÿ˜‰ but...

Some of the packages I vendor have switched from using X.Y.Z format tags to vX.Y.Z, and I didn't notice this and bumped the version. Running vndr was then giving me:

$ vndr github.com/labstack/gommon 0.2.8
2019/06/05 15:36:05 Collecting initial packages
2019/06/05 15:36:20 Download dependencies
2019/06/05 15:36:20 	Clone github.com/labstack/gommon, revision 0.2.8
2019/06/05 15:36:23 	Finished clone github.com/labstack/gommon
2019/06/05 15:36:24 	Clone github.com/labstack/gommon, revision 0.2.8
2019/06/05 15:36:26 	Finished clone github.com/labstack/gommon
2019/06/05 15:36:27 	Clone github.com/labstack/gommon, revision 0.2.8
2019/06/05 15:36:29 	Finished clone github.com/labstack/gommon
2019/06/05 15:36:30 	Clone github.com/labstack/gommon, revision 0.2.8
... and so on ...

It took me quite a while to figure out what was going on but of course changing 0.2.8 to v0.2.8 fixed it. It would be nice if vndr issued an error for bad tags instead of retrying forever.

Handling of nested-vendoring

If I vendor a package which itself vendors stuff then I somehow need to ensure that I satisfy the requirements of that package.

I'll use swarmkit as an example. If I vendor docker/swarmkit into my project then I also need to pickup the contents of docker/swarmkit/vendor.conf somehow.

Before I switched to vndr I was simply dumping a copy of docker/swarmkit into vendor/github.com/docker/swarmkit, including the vendor/github.com/docker/swarmkit/vendor directory. This almost worked since go will consult vendor/github.com/docker/swarmkit/vendor while building vendor/github.com/docker/swarmkit (but not otherwise, which is quite nice for encapsulation).

However it didn't actually work because vendor/golang.org/x/net/context/ is treated as distinct from vendor/github.com/docker/swarmkit/vendor/golang.org/x/net/context/ and hence the Context objects used in my project could not be passed to Swarmkit functions (since the types don't match).

My manual solution was to "promote" (with mv(1)) the subset of packages which need to cross the API boundary from vendor/github.com/docker/swarmkit/vendor to my project's vendor dir. In practice this was a fairly small/manageable subset (golang.org/x/net, google.golang.org/grpc and github.com/golang/protobuf).

With vndr I toyed with removing the code which removes nested vendor directories, but that suffers from the type mismatch problem mentioned. There is no mechanism with vndr to promote things in the way that I was doing.

I ended up simply lifting the whole of docker/swarmkit/vendor.conf into my vendor.conf, but that's rather manual (and prone to getting out of date). I'm not sure what other way this could be handled. Some half baked thoughts:

  • A way to #include a vendor.conf provided by a vendored component wholesale
  • A way to say "use the version given by this other vendor.conf" as a way to "promote" things. In this case the nested-vendor directories would need to be at least partially preserved too (for all the non-promoted stuff)

Neither of those seem like perfect options though.

vndr erasing multiple dependencies on run

I started porting multiple projects to the Risc-V and found a weird bug on vndr.

I'm updating containerd dependencies and have cloned it into a NFS partition. Then updated vendor.conf with new packages and when I run it after a while vndr removes many packages that are not supposed to be removed.

Here is the log:

โžœ vndr
2019/06/07 18:34:07 Collecting initial packages
2019/06/07 18:34:16 Download dependencies
2019/06/07 18:34:22 Starting whole vndr cycle because no package specified
2019/06/07 18:34:42 	Clone github.com/containerd/go-runc, revision 5a6d9f37cfa36b15efba46dc7ea349fa9b7143c3, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/containerd/btrfs, revision af5082808c833de0e79c1e72eea9fea239364877, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/containerd/aufs, revision f894a800659b6e11c1a13084abd1712f346e349c, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/containerd/console, revision 0650fd9eeb50bab4fc99dceb9f2e14cf58f36e7f, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/docker/go-metrics, revision 4ea375f7759c82740c893fc030bc37088d2ec098, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/docker/go-events, revision 9461782956ad83b30282bf90e31fa6a70c255ba9, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/coreos/go-systemd, revision 48702e0da86bd25e76cfef347e2adeb434a0d0a6, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/containerd/cgroups, revision 4994991857f9b0ae8dc439551e8bebdbb4bf66c1, attempt 1/20
2019/06/07 18:34:42 	Clone go.etcd.io/bbolt, revision 2eb7227adea1d5cf85f0bc2a82b7059b13c2fa68, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/docker/go-units, revision v0.4.0, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/containerd/cri, revision 2fc62db8146ce66f27b37306ad5fda34207835f3, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/containerd/go-cni, revision 891c2a41e18144b2d7921f971d6c9789a68046b2, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/containerd/continuity, revision bd77b46c8352f74eb12c85bdc01f4b90f69d66b4, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/containerd/typeurl, revision a93fcdb778cd272c6e9b3028b2f42d813e785d40, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/containerd/fifo, revision 3d5202aec260678c48179c56f40e6f38a095738c, attempt 1/20
2019/06/07 18:34:42 	Clone github.com/godbus/dbus, revision c7fdd8b5cd55e87b4e1f4e372cdb1db61dd6c66f, attempt 1/20
2019/06/07 18:35:00 	Finished clone github.com/docker/go-units
2019/06/07 18:35:00 	Clone github.com/prometheus/client_golang, revision f4fb1b73fb099f396a7f0036bf86aa8def4ed823, attempt 1/20
2019/06/07 18:35:01 	Finished clone github.com/containerd/btrfs
2019/06/07 18:35:01 	Clone github.com/prometheus/client_model, revision 99fa1f4be8e564e8a6b613da7fa6f46c9edafc6c, attempt 1/20
2019/06/07 18:35:01 	Finished clone github.com/containerd/go-runc
2019/06/07 18:35:01 	Clone github.com/prometheus/common, revision 89604d197083d4781071d3c65855d24ecfb0a563, attempt 1/20
2019/06/07 18:35:01 	Finished clone github.com/containerd/console
2019/06/07 18:35:01 	Clone github.com/prometheus/procfs, revision cb4147076ac75738c9a7d279075a253c0cc5acbd, attempt 1/20
2019/06/07 18:35:01 	Finished clone github.com/containerd/fifo
2019/06/07 18:35:01 	Clone github.com/beorn7/perks, revision 4c0e84591b9aa9e6dcfdf3e020114cd81f89d5f9, attempt 1/20
2019/06/07 18:35:01 	Finished clone github.com/docker/go-metrics
2019/06/07 18:35:01 	Clone github.com/matttproud/golang_protobuf_extensions, revision v1.0.1, attempt 1/20
2019/06/07 18:35:05 	Finished clone github.com/containerd/cgroups
2019/06/07 18:35:05 	Clone github.com/gogo/protobuf, revision v1.2.1, attempt 1/20
2019/06/07 18:35:06 	Finished clone go.etcd.io/bbolt
2019/06/07 18:35:06 	Clone github.com/gogo/googleapis, revision v1.2.0, attempt 1/20
2019/06/07 18:35:08 	Finished clone github.com/containerd/go-cni
2019/06/07 18:35:08 	Clone github.com/golang/protobuf, revision v1.2.0, attempt 1/20
2019/06/07 18:35:09 	Finished clone github.com/containerd/typeurl
2019/06/07 18:35:09 	Clone github.com/opencontainers/runtime-spec, revision 29686dbc5559d93fb1ef402eeda3e35c38d75af4, attempt 1/20
2019/06/07 18:35:09 	Finished clone github.com/godbus/dbus
2019/06/07 18:35:09 	Clone github.com/containernetworking/cni, revision v0.6.0, attempt 1/20
2019/06/07 18:35:10 	Finished clone github.com/containerd/aufs
2019/06/07 18:35:10 	Clone github.com/containernetworking/plugins, revision v0.7.0, attempt 1/20
2019/06/07 18:35:10 	Finished clone github.com/coreos/go-systemd
2019/06/07 18:35:10 	Clone github.com/opencontainers/runc, revision v1.0.0-rc8, attempt 1/20
2019/06/07 18:35:17 	Finished clone github.com/docker/go-events
2019/06/07 18:35:17 	Clone github.com/konsorten/go-windows-terminal-sequences, revision v1.0.1, attempt 1/20
2019/06/07 18:35:18 	Finished clone github.com/matttproud/golang_protobuf_extensions
2019/06/07 18:35:18 	Clone github.com/davecgh/go-spew, revision v1.1.0, attempt 1/20
2019/06/07 18:35:19 	Finished clone github.com/beorn7/perks
2019/06/07 18:35:19 	Clone github.com/sirupsen/logrus, revision v1.4.1, attempt 1/20
2019/06/07 18:35:22 	Finished clone github.com/gogo/googleapis
2019/06/07 18:35:22 	Clone github.com/docker/distribution, revision 0d3efadf0154c2b8a4e7b6621fff9809655cc580, attempt 1/20
2019/06/07 18:35:22 	Finished clone github.com/prometheus/client_model
2019/06/07 18:35:22 	Clone github.com/urfave/cli, revision 7bc6a0acffa589f415f88aca16cc1de5ffd66f9c, attempt 1/20
2019/06/07 18:35:33 	Finished clone github.com/prometheus/common
2019/06/07 18:35:33 	Clone golang.org/x/net, revision f3200d17e092c607f615320ecaad13d87ad9a2b3, attempt 1/20
2019/06/07 18:35:33 	Finished clone github.com/opencontainers/runtime-spec
2019/06/07 18:35:33 	Clone github.com/docker/docker, revision 86f080cff0914e9694068ed78d503701667c4c00, attempt 1/20
2019/06/07 18:35:34 	Finished clone github.com/prometheus/procfs
2019/06/07 18:35:34 	Clone google.golang.org/grpc, revision 25c4f928eaa6d96443009bd842389fb4fa48664e, attempt 1/20
2019/06/07 18:35:35 	Finished clone github.com/prometheus/client_golang
2019/06/07 18:35:35 	Clone github.com/docker/spdystream, revision 449fdfce4d962303d702fec724ef0ad181c92528, attempt 1/20
2019/06/07 18:35:41 	Finished clone github.com/davecgh/go-spew
2019/06/07 18:35:41 	Clone github.com/pkg/errors, revision v0.8.1, attempt 1/20
2019/06/07 18:35:42 	Finished clone github.com/konsorten/go-windows-terminal-sequences
2019/06/07 18:35:42 	Clone github.com/opencontainers/go-digest, revision c9281466c8b2f606084ac71339773efd177436e7, attempt 1/20
2019/06/07 18:35:47 	Finished clone github.com/sirupsen/logrus
2019/06/07 18:35:47 	Clone https://github.com/golang/sys to golang.org/x/sys, revision 4c4f7f33c9ed00de01c4c741d2177abfcfe19307, attempt 1/20
2019/06/07 18:35:51 	Finished clone github.com/urfave/cli
2019/06/07 18:35:51 	Clone github.com/opencontainers/image-spec, revision v1.0.1, attempt 1/20
2019/06/07 18:35:56 	Finished clone github.com/docker/spdystream
2019/06/07 18:35:56 	Clone github.com/emicklei/go-restful, revision v2.2.1, attempt 1/20
2019/06/07 18:35:59 	Finished clone github.com/containerd/continuity
2019/06/07 18:35:59 	Clone github.com/google/gofuzz, revision 44d81051d367757e1c7c6a5a86423ece9afcf63c, attempt 1/20
2019/06/07 18:36:02 	Finished clone github.com/pkg/errors
2019/06/07 18:36:02 	Clone github.com/hashicorp/errwrap, revision 7554cd9344cec97297fa6649b055a8c98c2a1e55, attempt 1/20
2019/06/07 18:36:02 	Finished clone github.com/opencontainers/go-digest
2019/06/07 18:36:02 	Clone github.com/hashicorp/go-multierror, revision ed905158d87462226a13fe39ddf685ea65f1c11f, attempt 1/20
2019/06/07 18:36:05 	Finished clone github.com/containernetworking/cni
2019/06/07 18:36:05 	Clone github.com/json-iterator/go, revision 1.1.5, attempt 1/20
2019/06/07 18:36:13 	Finished clone github.com/golang/protobuf
2019/06/07 18:36:13 	Clone github.com/modern-go/reflect2, revision 1.0.1, attempt 1/20
2019/06/07 18:36:26 	Finished clone github.com/hashicorp/go-multierror
2019/06/07 18:36:26 	Clone github.com/modern-go/concurrent, revision 1.0.3, attempt 1/20
2019/06/07 18:36:29 	Finished clone github.com/opencontainers/image-spec
2019/06/07 18:36:29 	Clone github.com/opencontainers/selinux, revision v1.2.2, attempt 1/20
2019/06/07 18:36:35 	Finished clone github.com/hashicorp/errwrap
2019/06/07 18:36:35 	Clone github.com/seccomp/libseccomp-golang, revision 32f571b70023028bd57d9288c20efbcb237f3ce0, attempt 1/20
2019/06/07 18:36:37 	Finished clone github.com/modern-go/reflect2
2019/06/07 18:36:37 	Clone github.com/tchap/go-patricia, revision v2.2.6, attempt 1/20
2019/06/07 18:36:43 	Finished clone github.com/emicklei/go-restful
2019/06/07 18:36:43 	Clone golang.org/x/crypto, revision 88737f569e3a9c7ab309cdc09a07fe7fc87233c3, attempt 1/20
2019/06/07 18:36:43 	Finished clone github.com/google/gofuzz
2019/06/07 18:36:43 	Clone golang.org/x/oauth2, revision a6bd8cefa1811bd24b86f8902872e4e8225f74c4, attempt 1/20
2019/06/07 18:36:50 	Finished clone github.com/opencontainers/selinux
2019/06/07 18:36:50 	Clone golang.org/x/time, revision f51c12702a4d776e4c1fa9b0fabab841babae631, attempt 1/20
2019/06/07 18:36:52 	Finished clone github.com/json-iterator/go
2019/06/07 18:36:52 	Clone gopkg.in/inf.v0, revision 3887ee99ecf07df5b447e9b00d9c0b2adaa9f3e4, attempt 1/20
2019/06/07 18:36:56 	Finished clone github.com/seccomp/libseccomp-golang
2019/06/07 18:36:56 	Clone gopkg.in/yaml.v2, revision v2.2.1, attempt 1/20
2019/06/07 18:36:59 	Finished clone github.com/tchap/go-patricia
2019/06/07 18:36:59 	Clone k8s.io/api, revision kubernetes-1.15.0-alpha.0, attempt 1/20
2019/06/07 18:37:07 	Finished clone github.com/modern-go/concurrent
2019/06/07 18:37:07 	Clone k8s.io/apimachinery, revision kubernetes-1.15.0-alpha.0, attempt 1/20
2019/06/07 18:37:13 	Finished clone gopkg.in/inf.v0
2019/06/07 18:37:13 	Clone k8s.io/apiserver, revision kubernetes-1.15.0-alpha.0, attempt 1/20
2019/06/07 18:37:21 	Finished clone gopkg.in/yaml.v2
2019/06/07 18:37:21 	Clone k8s.io/client-go, revision kubernetes-1.15.0-alpha.0, attempt 1/20
2019/06/07 18:37:21 	Finished clone golang.org/x/oauth2
2019/06/07 18:37:21 	Clone k8s.io/klog, revision 8139d8cb77af419532b33dfa7dd09fbc5f1d344f, attempt 1/20
2019/06/07 18:37:27 	Finished clone golang.org/x/sys
2019/06/07 18:37:27 	Clone k8s.io/kubernetes, revision v1.15.0-alpha.0, attempt 1/20
2019/06/07 18:37:29 	Finished clone golang.org/x/time
2019/06/07 18:37:29 	Clone k8s.io/utils, revision c2654d5206da6b7b6ace12841e8f359bb89b443c, attempt 1/20
2019/06/07 18:37:36 	Finished clone github.com/opencontainers/runc
2019/06/07 18:37:36 	Clone sigs.k8s.io/yaml, revision v1.1.0, attempt 1/20
2019/06/07 18:37:38 	Finished clone google.golang.org/grpc
2019/06/07 18:37:38 	Clone github.com/containerd/zfs, revision 31af176f2ae84fe142ef2655bf7bb2aa618b3b1f, attempt 1/20
2019/06/07 18:37:41 	Finished clone golang.org/x/net
2019/06/07 18:37:41 	Clone github.com/mistifyio/go-zfs, revision f784269be439d704d3dfa1906f45dd848fed2beb, attempt 1/20
2019/06/07 18:37:45 	Clone github.com/google/uuid, revision v1.1.1, attempt 1/20
2019/06/07 18:37:45 	Finished clone k8s.io/klog
2019/06/07 18:37:55 	Finished clone golang.org/x/crypto
2019/06/07 18:37:55 	Clone golang.org/x/sync, revision 42b317875d0fa942474b76e1b46a6060d720ae6e, attempt 1/20
2019/06/07 18:37:56 	Finished clone github.com/containerd/zfs
2019/06/07 18:37:56 	Clone github.com/BurntSushi/toml, revision v0.3.1, attempt 1/20
2019/06/07 18:37:57 	Finished clone k8s.io/utils
2019/06/07 18:37:57 	Clone github.com/Microsoft/go-winio, revision 84b4ab48a50763fe7b3abcef38e5205c12027fac, attempt 1/20
2019/06/07 18:38:00 	Finished clone github.com/mistifyio/go-zfs
2019/06/07 18:38:00 	Clone github.com/Microsoft/hcsshim, revision 8abdbb8205e4192c68b5f84c31197156f31be517, attempt 1/20
2019/06/07 18:38:04 	Finished clone sigs.k8s.io/yaml
2019/06/07 18:38:04 	Clone google.golang.org/genproto, revision d80a6e20e776b0b17a324d0ba1ab50a39c8e8944, attempt 1/20
2019/06/07 18:38:05 	Finished clone github.com/google/uuid
2019/06/07 18:38:05 	Clone golang.org/x/text, revision 19e51611da83d6be54ddafce4a4af510cb3e9ea4, attempt 1/20
2019/06/07 18:38:14 	Finished clone golang.org/x/sync
2019/06/07 18:38:14 	Clone github.com/containerd/ttrpc, revision a5bd8ce9e40bc7c065a11c6936f4d032ce6bfa2b, attempt 1/20
2019/06/07 18:38:18 	Finished clone github.com/BurntSushi/toml
2019/06/07 18:38:18 	Clone github.com/syndtr/gocapability, revision d98352740cb2c55f81556b63d4a1ec64c5a319c2, attempt 1/20
2019/06/07 18:38:24 	Finished clone github.com/Microsoft/go-winio
2019/06/07 18:38:24 	Clone gotest.tools, revision v2.3.0, attempt 1/20
2019/06/07 18:38:32 	Finished clone github.com/containerd/ttrpc
2019/06/07 18:38:32 	Clone github.com/google/go-cmp, revision v0.2.0, attempt 1/20
2019/06/07 18:38:36 	Finished clone github.com/syndtr/gocapability
2019/06/07 18:38:36 	Clone github.com/grpc-ecosystem/go-grpc-prometheus, revision 6b7015e65d366bf3f19b2b2a000a831940f0f7e0, attempt 1/20
2019/06/07 18:38:53 	Finished clone github.com/docker/distribution
2019/06/07 18:38:57 	Finished clone github.com/gogo/protobuf
2019/06/07 18:38:58 	Finished clone gotest.tools
2019/06/07 18:38:59 	Finished clone github.com/grpc-ecosystem/go-grpc-prometheus
2019/06/07 18:38:59 	Finished clone github.com/google/go-cmp
2019/06/07 18:39:15 	Finished clone k8s.io/apimachinery
2019/06/07 18:39:51 	Finished clone github.com/containernetworking/plugins
2019/06/07 18:39:58 	Finished clone github.com/containerd/cri
2019/06/07 18:40:04 	Finished clone golang.org/x/text
2019/06/07 18:40:35 	Finished clone google.golang.org/genproto
2019/06/07 18:40:47 	Finished clone github.com/Microsoft/hcsshim
2019/06/07 18:40:51 	Finished clone k8s.io/client-go
2019/06/07 18:41:03 	Finished clone k8s.io/api
2019/06/07 18:41:18 	Finished clone k8s.io/apiserver
2019/06/07 18:44:23 	Finished clone github.com/docker/docker

2019/06/07 18:57:36 	Finished clone k8s.io/kubernetes
2019/06/07 18:57:36 Dependencies downloaded. Download time: 22m54.261455678s
2019/06/07 18:57:36 Collecting all dependencies
2019/06/07 18:57:36 WARNING: dependency is not vendored: github.com/gogo/protobuf/proto
2019/06/07 18:57:37 WARNING: dependency is not vendored: github.com/gogo/protobuf/types
2019/06/07 18:57:38 WARNING: dependency is not vendored: github.com/gogo/protobuf/sortkeys
2019/06/07 18:57:40 WARNING: dependency is not vendored: github.com/Microsoft/go-winio
2019/06/07 18:57:40 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim
2019/06/07 18:57:40 WARNING: dependency is not vendored: github.com/containerd/typeurl
2019/06/07 18:57:40 WARNING: dependency is not vendored: github.com/opencontainers/image-spec/specs-go/v1
2019/06/07 18:57:40 WARNING: dependency is not vendored: github.com/opencontainers/runtime-spec/specs-go
2019/06/07 18:57:40 WARNING: dependency is not vendored: github.com/pkg/errors
2019/06/07 18:57:40 WARNING: dependency is not vendored: github.com/sirupsen/logrus
2019/06/07 18:57:43 WARNING: dependency is not vendored: github.com/konsorten/go-windows-terminal-sequences
2019/06/07 18:57:45 WARNING: dependency is not vendored: golang.org/x/sys/unix
2019/06/07 18:57:50 WARNING: dependency is not vendored: github.com/opencontainers/go-digest
2019/06/07 18:57:50 WARNING: dependency is not vendored: github.com/opencontainers/image-spec/specs-go
2019/06/07 18:57:51 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/guid
2019/06/07 18:57:51 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/hcs
2019/06/07 18:57:51 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/hcserror
2019/06/07 18:57:51 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/hns
2019/06/07 18:57:51 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/mergemaps
2019/06/07 18:57:51 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/schema1
2019/06/07 18:57:51 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/wclayer
2019/06/07 18:57:51 WARNING: dependency is not vendored: golang.org/x/sys/windows
2019/06/07 18:57:52 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/interop
2019/06/07 18:57:52 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/longpath
2019/06/07 18:57:52 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/safefile
2019/06/07 18:57:54 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/schema2
2019/06/07 18:57:55 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/guestrequest
2019/06/07 18:57:55 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/logfields
2019/06/07 18:57:55 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/timeout
2019/06/07 18:57:57 WARNING: dependency is not vendored: github.com/opencontainers/runc/libcontainer/system
2019/06/07 18:57:57 WARNING: dependency is not vendored: github.com/containerd/continuity/fs/fstest
2019/06/07 18:57:57 WARNING: dependency is not vendored: gotest.tools/assert
2019/06/07 18:57:58 WARNING: dependency is not vendored: gotest.tools/assert/cmp
2019/06/07 18:57:58 WARNING: dependency is not vendored: github.com/google/go-cmp/cmp
2019/06/07 18:57:58 WARNING: dependency is not vendored: gotest.tools/internal/format
2019/06/07 18:57:58 WARNING: dependency is not vendored: gotest.tools/internal/source
2019/06/07 18:57:59 WARNING: dependency is not vendored: gotest.tools/internal/difflib
2019/06/07 18:57:59 WARNING: dependency is not vendored: github.com/google/go-cmp/cmp/internal/diff
2019/06/07 18:57:59 WARNING: dependency is not vendored: github.com/google/go-cmp/cmp/internal/function
2019/06/07 18:57:59 WARNING: dependency is not vendored: github.com/google/go-cmp/cmp/internal/value
2019/06/07 18:58:00 WARNING: dependency is not vendored: github.com/containerd/continuity
2019/06/07 18:58:00 WARNING: dependency is not vendored: github.com/containerd/continuity/sysx
2019/06/07 18:58:00 WARNING: dependency is not vendored: github.com/containerd/continuity/syscallx
2019/06/07 18:58:01 WARNING: dependency is not vendored: github.com/containerd/continuity/devices
2019/06/07 18:58:02 WARNING: dependency is not vendored: github.com/containerd/continuity/driver
2019/06/07 18:58:02 WARNING: dependency is not vendored: github.com/containerd/continuity/pathdriver
2019/06/07 18:58:02 WARNING: dependency is not vendored: github.com/containerd/continuity/proto
2019/06/07 18:58:02 WARNING: dependency is not vendored: github.com/golang/protobuf/proto
2019/06/07 18:58:03 WARNING: dependency is not vendored: github.com/opencontainers/runc/libcontainer/user
2019/06/07 18:58:04 WARNING: dependency is not vendored: github.com/Microsoft/go-winio/vhd
2019/06/07 18:58:04 WARNING: dependency is not vendored: github.com/containerd/continuity/fs
2019/06/07 18:58:04 WARNING: dependency is not vendored: golang.org/x/sync/errgroup
2019/06/07 18:58:06 WARNING: dependency is not vendored: go.etcd.io/bbolt
2019/06/07 18:58:07 WARNING: dependency is not vendored: github.com/containerd/continuity/testutil/loopback
2019/06/07 18:58:08 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/pkg/go-runhcs
2019/06/07 18:58:08 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/internal/runhcs
2019/06/07 18:58:09 WARNING: dependency is not vendored: github.com/containerd/go-runc
2019/06/07 18:58:09 WARNING: dependency is not vendored: github.com/containerd/console
2019/06/07 18:58:10 WARNING: dependency is not vendored: github.com/docker/go-units
2019/06/07 18:58:10 WARNING: dependency is not vendored: github.com/BurntSushi/toml
2019/06/07 18:58:10 WARNING: dependency is not vendored: github.com/hashicorp/go-multierror
2019/06/07 18:58:11 WARNING: dependency is not vendored: github.com/hashicorp/errwrap
2019/06/07 18:58:11 WARNING: dependency is not vendored: github.com/containerd/btrfs
2019/06/07 18:58:12 WARNING: dependency is not vendored: google.golang.org/grpc
2019/06/07 18:58:13 WARNING: dependency is not vendored: golang.org/x/net/trace
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/balancer
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/balancer/roundrobin
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/codes
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/connectivity
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/credentials
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/encoding
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/encoding/proto
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/grpclog
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/internal
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/internal/backoff
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/internal/balancerload
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/internal/binarylog
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/internal/channelz
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/internal/envconfig
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/internal/grpcrand
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/internal/grpcsync
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/internal/transport
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/keepalive
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/metadata
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/naming
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/peer
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/resolver
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/resolver/dns
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/resolver/passthrough
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/stats
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/status
2019/06/07 18:58:13 WARNING: dependency is not vendored: google.golang.org/grpc/tap
2019/06/07 18:58:14 WARNING: dependency is not vendored: github.com/golang/protobuf/ptypes
2019/06/07 18:58:14 WARNING: dependency is not vendored: google.golang.org/genproto/googleapis/rpc/status
2019/06/07 18:58:14 WARNING: dependency is not vendored: github.com/golang/protobuf/ptypes/any
2019/06/07 18:58:14 WARNING: dependency is not vendored: github.com/golang/protobuf/ptypes/duration
2019/06/07 18:58:14 WARNING: dependency is not vendored: github.com/golang/protobuf/ptypes/timestamp
2019/06/07 18:58:16 WARNING: dependency is not vendored: golang.org/x/net/http2
2019/06/07 18:58:16 WARNING: dependency is not vendored: golang.org/x/net/http2/hpack
2019/06/07 18:58:16 WARNING: dependency is not vendored: google.golang.org/grpc/internal/syscall
2019/06/07 18:58:17 WARNING: dependency is not vendored: golang.org/x/net/http/httpguts
2019/06/07 18:58:17 WARNING: dependency is not vendored: golang.org/x/net/idna
2019/06/07 18:58:18 WARNING: dependency is not vendored: golang.org/x/text/secure/bidirule
2019/06/07 18:58:18 WARNING: dependency is not vendored: golang.org/x/text/unicode/bidi
2019/06/07 18:58:19 WARNING: dependency is not vendored: golang.org/x/text/unicode/norm
2019/06/07 18:58:19 WARNING: dependency is not vendored: golang.org/x/text/transform
2019/06/07 18:58:20 WARNING: dependency is not vendored: google.golang.org/grpc/binarylog/grpc_binarylog_v1
2019/06/07 18:58:21 WARNING: dependency is not vendored: google.golang.org/grpc/credentials/internal
2019/06/07 18:58:21 WARNING: dependency is not vendored: google.golang.org/grpc/balancer/base
2019/06/07 18:58:22 WARNING: dependency is not vendored: golang.org/x/net/internal/timeseries
2019/06/07 18:58:23 WARNING: dependency is not vendored: github.com/containerd/cgroups
2019/06/07 18:58:23 WARNING: dependency is not vendored: github.com/containerd/ttrpc
2019/06/07 18:58:23 WARNING: dependency is not vendored: github.com/docker/go-metrics
2019/06/07 18:58:23 WARNING: dependency is not vendored: github.com/grpc-ecosystem/go-grpc-prometheus
2019/06/07 18:58:24 WARNING: dependency is not vendored: github.com/prometheus/client_golang/prometheus
2019/06/07 18:58:24 WARNING: dependency is not vendored: golang.org/x/net/context
2019/06/07 18:58:24 WARNING: dependency is not vendored: github.com/beorn7/perks/quantile
2019/06/07 18:58:24 WARNING: dependency is not vendored: github.com/prometheus/client_model/go
2019/06/07 18:58:24 WARNING: dependency is not vendored: github.com/prometheus/common/expfmt
2019/06/07 18:58:24 WARNING: dependency is not vendored: github.com/prometheus/common/model
2019/06/07 18:58:24 WARNING: dependency is not vendored: github.com/prometheus/procfs
2019/06/07 18:58:25 WARNING: dependency is not vendored: github.com/prometheus/procfs/nfs
2019/06/07 18:58:25 WARNING: dependency is not vendored: github.com/prometheus/procfs/xfs
2019/06/07 18:58:26 WARNING: dependency is not vendored: github.com/prometheus/procfs/internal/util
2019/06/07 18:58:26 WARNING: dependency is not vendored: github.com/matttproud/golang_protobuf_extensions/pbutil
2019/06/07 18:58:26 WARNING: dependency is not vendored: github.com/prometheus/common/internal/bitbucket.org/ww/goautoneg
2019/06/07 18:58:28 WARNING: dependency is not vendored: github.com/coreos/go-systemd/dbus
2019/06/07 18:58:28 WARNING: dependency is not vendored: github.com/godbus/dbus
2019/06/07 18:58:28 WARNING: dependency is not vendored: github.com/gogo/protobuf/gogoproto
2019/06/07 18:58:28 WARNING: dependency is not vendored: github.com/gogo/protobuf/protoc-gen-gogo/descriptor
2019/06/07 18:58:30 WARNING: dependency is not vendored: github.com/gogo/googleapis/google/rpc
2019/06/07 18:58:30 WARNING: dependency is not vendored: google.golang.org/grpc/health
2019/06/07 18:58:30 WARNING: dependency is not vendored: google.golang.org/grpc/health/grpc_health_v1
2019/06/07 18:58:31 WARNING: dependency is not vendored: github.com/containerd/fifo
2019/06/07 18:58:38 WARNING: dependency is not vendored: github.com/opencontainers/image-spec/identity
2019/06/07 18:58:38 WARNING: dependency is not vendored: github.com/docker/distribution/registry/api/errcode
2019/06/07 18:58:38 WARNING: dependency is not vendored: golang.org/x/net/context/ctxhttp
2019/06/07 18:58:39 WARNING: dependency is not vendored: github.com/gogo/protobuf/protoc-gen-gogo/generator
2019/06/07 18:58:39 WARNING: dependency is not vendored: github.com/gogo/protobuf/protoc-gen-gogo/generator/internal/remap
2019/06/07 18:58:39 WARNING: dependency is not vendored: github.com/gogo/protobuf/protoc-gen-gogo/plugin
2019/06/07 18:58:42 WARNING: dependency is not vendored: github.com/syndtr/gocapability/capability
2019/06/07 18:58:44 WARNING: dependency is not vendored: github.com/containerd/continuity/testutil
2019/06/07 18:58:46 WARNING: dependency is not vendored: github.com/docker/distribution/reference
2019/06/07 18:58:46 WARNING: dependency is not vendored: github.com/docker/distribution/digestset
2019/06/07 18:58:46 WARNING: dependency is not vendored: golang.org/x/sync/semaphore
2019/06/07 18:58:47 WARNING: dependency is not vendored: github.com/docker/go-events
2019/06/07 18:58:47 WARNING: dependency is not vendored: github.com/Microsoft/go-winio/pkg/security
2019/06/07 18:58:47 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/ext4/tar2ext4
2019/06/07 18:58:47 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/ext4/internal/compactext4
2019/06/07 18:58:47 WARNING: dependency is not vendored: github.com/Microsoft/hcsshim/ext4/internal/format
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/containerd/ttrpc/plugin
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/vanity
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/vanity/command
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/compare
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/defaultcheck
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/description
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/embedcheck
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/enumstringer
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/equal
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/face
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/gostring
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/marshalto
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/oneofcheck
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/populate
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/size
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/stringer
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/testgen
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/union
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/plugin/unmarshal
2019/06/07 18:58:51 WARNING: dependency is not vendored: github.com/gogo/protobuf/protoc-gen-gogo/grpc
2019/06/07 18:58:52 WARNING: dependency is not vendored: github.com/urfave/cli
2019/06/07 18:58:56 WARNING: dependency is not vendored: github.com/containerd/cri/cli
2019/06/07 18:58:56 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/api/v1
2019/06/07 18:58:56 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/client
2019/06/07 18:58:56 WARNING: dependency is not vendored: k8s.io/kubernetes/pkg/kubelet/util
2019/06/07 18:58:56 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/apis/meta/v1
2019/06/07 18:58:56 WARNING: dependency is not vendored: k8s.io/klog
2019/06/07 18:58:57 WARNING: dependency is not vendored: github.com/google/gofuzz
2019/06/07 18:58:57 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/api/resource
2019/06/07 18:58:58 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/conversion
2019/06/07 18:58:58 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/fields
2019/06/07 18:58:58 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/labels
2019/06/07 18:58:58 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/runtime
2019/06/07 18:58:58 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/runtime/schema
2019/06/07 18:58:58 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/selection
2019/06/07 18:58:58 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/types
2019/06/07 18:58:58 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/intstr
2019/06/07 18:58:58 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/runtime
2019/06/07 18:58:58 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/watch
2019/06/07 18:58:58 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/net
2019/06/07 18:58:58 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/sets
2019/06/07 18:59:00 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/conversion/queryparams
2019/06/07 18:59:00 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/errors
2019/06/07 18:59:00 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/json
2019/06/07 18:59:00 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/naming
2019/06/07 18:59:01 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/validation
2019/06/07 18:59:01 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/validation/field
2019/06/07 18:59:01 WARNING: dependency is not vendored: k8s.io/apimachinery/third_party/forked/golang/reflect
2019/06/07 18:59:01 WARNING: dependency is not vendored: gopkg.in/inf.v0
2019/06/07 18:59:04 WARNING: dependency is not vendored: github.com/Microsoft/go-winio/pkg/etw
2019/06/07 18:59:04 WARNING: dependency is not vendored: github.com/Microsoft/go-winio/pkg/etwlogrus
2019/06/07 18:59:04 WARNING: dependency is not vendored: github.com/Microsoft/go-winio/pkg/guid
2019/06/07 18:59:04 WARNING: dependency is not vendored: golang.org/x/sys/windows/svc
2019/06/07 18:59:04 WARNING: dependency is not vendored: golang.org/x/sys/windows/svc/debug
2019/06/07 18:59:04 WARNING: dependency is not vendored: golang.org/x/sys/windows/svc/eventlog
2019/06/07 18:59:04 WARNING: dependency is not vendored: golang.org/x/sys/windows/svc/mgr
2019/06/07 18:59:05 WARNING: dependency is not vendored: golang.org/x/sys/windows/registry
2019/06/07 18:59:07 WARNING: dependency is not vendored: github.com/containerd/aufs
2019/06/07 18:59:07 WARNING: dependency is not vendored: github.com/containerd/cri
2019/06/07 18:59:07 WARNING: dependency is not vendored: github.com/containerd/zfs
2019/06/07 18:59:07 WARNING: dependency is not vendored: github.com/mistifyio/go-zfs
2019/06/07 18:59:08 WARNING: dependency is not vendored: github.com/google/uuid
2019/06/07 18:59:08 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/config
2019/06/07 18:59:08 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/constants
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/server
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/annotations
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/api/runtimeoptions/v1
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/atomic
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/containerd/importer
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/containerd/opts
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/containerd/util
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/ioutil
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/log
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/netns
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/os
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/registrar
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/server/io
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/store
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/store/container
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/store/image
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/store/sandbox
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/store/snapshot
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/cri/pkg/util
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containerd/go-cni
2019/06/07 18:59:09 WARNING: dependency is not vendored: github.com/containernetworking/plugins/pkg/ns
2019/06/07 18:59:10 WARNING: dependency is not vendored: github.com/davecgh/go-spew/spew
2019/06/07 18:59:10 WARNING: dependency is not vendored: github.com/docker/docker/pkg/system
2019/06/07 18:59:10 WARNING: dependency is not vendored: github.com/opencontainers/runc/libcontainer/apparmor
2019/06/07 18:59:10 WARNING: dependency is not vendored: github.com/opencontainers/runc/libcontainer/seccomp
2019/06/07 18:59:10 WARNING: dependency is not vendored: github.com/opencontainers/selinux/go-selinux
2019/06/07 18:59:10 WARNING: dependency is not vendored: github.com/opencontainers/selinux/go-selinux/label
2019/06/07 18:59:10 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/clock
2019/06/07 18:59:10 WARNING: dependency is not vendored: k8s.io/client-go/tools/remotecommand
2019/06/07 18:59:10 WARNING: dependency is not vendored: k8s.io/client-go/util/cert
2019/06/07 18:59:10 WARNING: dependency is not vendored: k8s.io/kubernetes/pkg/kubelet/apis/cri/runtime/v1alpha2
2019/06/07 18:59:10 WARNING: dependency is not vendored: k8s.io/kubernetes/pkg/kubelet/server/streaming
2019/06/07 18:59:10 WARNING: dependency is not vendored: k8s.io/utils/exec
2019/06/07 18:59:12 WARNING: dependency is not vendored: github.com/emicklei/go-restful
2019/06/07 18:59:12 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/remotecommand
2019/06/07 18:59:12 WARNING: dependency is not vendored: k8s.io/kubernetes/pkg/kubelet/server/portforward
2019/06/07 18:59:12 WARNING: dependency is not vendored: k8s.io/kubernetes/pkg/kubelet/server/remotecommand
2019/06/07 18:59:12 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/api/errors
2019/06/07 18:59:12 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/httpstream
2019/06/07 18:59:12 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/httpstream/spdy
2019/06/07 18:59:12 WARNING: dependency is not vendored: k8s.io/apiserver/pkg/server/httplog
2019/06/07 18:59:12 WARNING: dependency is not vendored: k8s.io/apiserver/pkg/util/wsstream
2019/06/07 18:59:12 WARNING: dependency is not vendored: k8s.io/kubernetes/pkg/apis/core
2019/06/07 18:59:13 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/apis/meta/internalversion
2019/06/07 18:59:13 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/apis/meta/v1beta1
2019/06/07 18:59:13 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/runtime/serializer
2019/06/07 18:59:13 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/runtime/serializer/json
2019/06/07 18:59:13 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/runtime/serializer/protobuf
2019/06/07 18:59:13 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/runtime/serializer/recognizer
2019/06/07 18:59:13 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/runtime/serializer/versioning
2019/06/07 18:59:13 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/apis/meta/v1/unstructured
2019/06/07 18:59:13 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/framer
2019/06/07 18:59:13 WARNING: dependency is not vendored: github.com/json-iterator/go
2019/06/07 18:59:14 WARNING: dependency is not vendored: github.com/modern-go/reflect2
2019/06/07 18:59:14 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/util/yaml
2019/06/07 18:59:14 WARNING: dependency is not vendored: sigs.k8s.io/yaml
2019/06/07 18:59:14 WARNING: dependency is not vendored: gopkg.in/yaml.v2
2019/06/07 18:59:14 WARNING: dependency is not vendored: github.com/modern-go/concurrent
2019/06/07 18:59:16 WARNING: dependency is not vendored: golang.org/x/net/websocket
2019/06/07 18:59:17 WARNING: dependency is not vendored: github.com/docker/spdystream
2019/06/07 18:59:17 WARNING: dependency is not vendored: k8s.io/apimachinery/third_party/forked/golang/netutil
2019/06/07 18:59:18 WARNING: dependency is not vendored: github.com/docker/spdystream/spdy
2019/06/07 18:59:19 WARNING: dependency is not vendored: github.com/emicklei/go-restful/log
2019/06/07 18:59:20 WARNING: dependency is not vendored: k8s.io/api/core/v1
2019/06/07 18:59:20 WARNING: dependency is not vendored: k8s.io/client-go/rest
2019/06/07 18:59:20 WARNING: dependency is not vendored: k8s.io/client-go/transport/spdy
2019/06/07 18:59:20 WARNING: dependency is not vendored: k8s.io/client-go/util/exec
2019/06/07 18:59:21 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/runtime/serializer/streaming
2019/06/07 18:59:21 WARNING: dependency is not vendored: k8s.io/client-go/pkg/version
2019/06/07 18:59:21 WARNING: dependency is not vendored: k8s.io/client-go/plugin/pkg/client/auth/exec
2019/06/07 18:59:21 WARNING: dependency is not vendored: k8s.io/client-go/rest/watch
2019/06/07 18:59:21 WARNING: dependency is not vendored: k8s.io/client-go/tools/clientcmd/api
2019/06/07 18:59:21 WARNING: dependency is not vendored: k8s.io/client-go/tools/metrics
2019/06/07 18:59:21 WARNING: dependency is not vendored: k8s.io/client-go/transport
2019/06/07 18:59:21 WARNING: dependency is not vendored: k8s.io/client-go/util/flowcontrol
2019/06/07 18:59:22 WARNING: dependency is not vendored: golang.org/x/time/rate
2019/06/07 18:59:22 WARNING: dependency is not vendored: k8s.io/utils/integer
2019/06/07 18:59:22 WARNING: dependency is not vendored: golang.org/x/oauth2
2019/06/07 18:59:22 WARNING: dependency is not vendored: golang.org/x/oauth2/internal
2019/06/07 18:59:23 WARNING: dependency is not vendored: golang.org/x/crypto/ssh/terminal
2019/06/07 18:59:23 WARNING: dependency is not vendored: k8s.io/client-go/pkg/apis/clientauthentication
2019/06/07 18:59:23 WARNING: dependency is not vendored: k8s.io/client-go/pkg/apis/clientauthentication/v1alpha1
2019/06/07 18:59:23 WARNING: dependency is not vendored: k8s.io/client-go/pkg/apis/clientauthentication/v1beta1
2019/06/07 18:59:23 WARNING: dependency is not vendored: k8s.io/client-go/util/connrotation
2019/06/07 18:59:24 WARNING: dependency is not vendored: k8s.io/apimachinery/pkg/version
2019/06/07 18:59:26 WARNING: dependency is not vendored: github.com/opencontainers/runc/libcontainer/configs
2019/06/07 18:59:26 WARNING: dependency is not vendored: github.com/seccomp/libseccomp-golang
2019/06/07 18:59:27 WARNING: dependency is not vendored: github.com/docker/docker/pkg/mount
2019/06/07 18:59:29 WARNING: dependency is not vendored: github.com/containernetworking/cni/libcni
2019/06/07 18:59:29 WARNING: dependency is not vendored: github.com/containernetworking/cni/pkg/types
2019/06/07 18:59:29 WARNING: dependency is not vendored: github.com/containernetworking/cni/pkg/types/current
2019/06/07 18:59:30 WARNING: dependency is not vendored: github.com/containernetworking/cni/pkg/types/020
2019/06/07 18:59:30 WARNING: dependency is not vendored: github.com/containernetworking/cni/pkg/invoke
2019/06/07 18:59:30 WARNING: dependency is not vendored: github.com/containernetworking/cni/pkg/version
2019/06/07 18:59:31 WARNING: dependency is not vendored: github.com/docker/docker/pkg/truncindex
2019/06/07 18:59:31 WARNING: dependency is not vendored: github.com/tchap/go-patricia/patricia
2019/06/07 18:59:32 WARNING: dependency is not vendored: github.com/docker/docker/pkg/symlink
2019/06/07 18:59:32 WARNING: dependency is not vendored: github.com/docker/docker/pkg/longpath
2019/06/07 18:59:32 WARNING: dependency is not vendored: github.com/opencontainers/runc/libcontainer/devices
2019/06/07 18:59:34 WARNING: dependency is not vendored: github.com/google/go-cmp/cmp/cmpopts
2019/06/07 18:59:41 Clean vendor dir from unused packages
2019/06/07 19:03:01 WARNING: package github.com/containerd/go-runc is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/containerd/console is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/containerd/cgroups is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/containerd/typeurl is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/containerd/fifo is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/containerd/continuity is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/coreos/go-systemd is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/docker/go-metrics is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/docker/go-events is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/docker/go-units is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/godbus/dbus is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/prometheus/client_golang is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/prometheus/client_model is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/prometheus/common is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/prometheus/procfs is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/beorn7/perks is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/matttproud/golang_protobuf_extensions is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/gogo/googleapis is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/golang/protobuf is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/opencontainers/runtime-spec is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/konsorten/go-windows-terminal-sequences is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/sirupsen/logrus is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/urfave/cli is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package golang.org/x/net is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package google.golang.org/grpc is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/pkg/errors is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/opencontainers/go-digest is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/opencontainers/image-spec is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package golang.org/x/sync is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/BurntSushi/toml is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/grpc-ecosystem/go-grpc-prometheus is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/Microsoft/go-winio is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/Microsoft/hcsshim is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package google.golang.org/genproto is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package golang.org/x/text is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/containerd/ttrpc is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/syndtr/gocapability is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package gotest.tools is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/google/go-cmp is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package go.etcd.io/bbolt is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/containerd/cri is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/containerd/go-cni is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/containernetworking/cni is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/containernetworking/plugins is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/davecgh/go-spew is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/docker/distribution is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/docker/spdystream is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/emicklei/go-restful is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/google/gofuzz is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/hashicorp/errwrap is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/hashicorp/go-multierror is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/json-iterator/go is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/modern-go/reflect2 is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/modern-go/concurrent is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/opencontainers/selinux is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/seccomp/libseccomp-golang is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/tchap/go-patricia is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package golang.org/x/oauth2 is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package golang.org/x/time is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package gopkg.in/inf.v0 is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package gopkg.in/yaml.v2 is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package k8s.io/api is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package k8s.io/apimachinery is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package k8s.io/apiserver is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package k8s.io/client-go is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package k8s.io/klog is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package k8s.io/utils is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package sigs.k8s.io/yaml is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/containerd/zfs is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/mistifyio/go-zfs is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/google/uuid is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 WARNING: package github.com/containerd/aufs is unused, consider removing it from vendor.conf
2019/06/07 19:03:01 Success
2019/06/07 19:03:01 Running time: 28m53.738412408s

Having the tree on NFS changes anything? Any idea on why vndr cleans up so many dependencies while it should only update the three I needed. Here is the PR in question: containerd/containerd#3328

Azure Go SDK

It seems that the latest version of Azure has git submodules.
Even with an older version pinned, I get some odd behaviors:

$ cat vendor.conf
github.com/Azure/azure-sdk-for-go c6f0533defaaaa26ea4dff3c9774e36033088112
$ vndr
2017/03/31 20:24:38 Collecting initial packages
2017/03/31 20:24:38 Download dependencies
2017/03/31 20:24:38 	Clone github.com/Azure/azure-sdk-for-go, revision c6f0533defaaaa26ea4dff3c9774e36033088112
2017/03/31 20:24:41 	Finished clone github.com/Azure/azure-sdk-for-go
2017/03/31 20:24:41 Errors on clone:
github.com/Azure/azure-sdk-for-go: Err: exit status 1, out: error: The following untracked working tree files would be overwritten by checkout:
	storage/README.md
	storage/blob.go
	storage/blob_test.go
	storage/client.go
	storage/client_test.go
	storage/file.go
	storage/file_test.go
	storage/queue.go
	storage/queue_test.go
	storage/table.go
	storage/table_entities.go
	storage/table_test.go
	storage/util.go
	storage/util_test.go
Please move or remove them before you can switch branches.

https://api.bitbucket.org/1.0/repositories/ww/goautoneg: 410 Gone

When vndr command is run, I see this:
https://api.bitbucket.org/1.0/repositories/ww/goautoneg: 410 Gone
which is in https://github.com/LK4D4/vndr/blob/master/godl/vcs.go

Tried to open the page https://api.bitbucket.org/1.0/repositories/ww/goautoneg:
{"type": "error", "error": {"message": "Resource removed", "detail": "This API is no longer supported.\n\nFor information about its removal, please refer to the deprecation notice at: https://developer.atlassian.com/cloud/bitbucket/deprecation-notice-v1-apis/"}}

Functionality to output cleaned up vendor.conf

I extracted Kubernetes dependencies from the client-go and apimachinery Godeps.json file and added them into my vendor.conf

#18 introduced sub-package collision checking but it is painful to fix vendor.conf by hand. This might also be true for the duplicate package warning.

Feature request is to add an option to make vndr output the fixed vendor.conf, choosing the shortest length subpackage as the collapsed single entry for that repo.

2017/04/07 17:35:45 Collecting initial packages
2017/04/07 17:35:45 Download dependencies
2017/04/07 17:35:45 Validation error: Each line below contains packages which has same repo, please remove subpackages from config:
        [k8s.io/apimachinery/pkg/util/validation k8s.io/apimachinery/pkg/util/validation/field]
        [golang.org/x/oauth2 golang.org/x/oauth2/google golang.org/x/oauth2/internal golang.org/x/oauth2/jws golang.org/x/oauth2/jwt]
        [github.com/golang/protobuf github.com/golang/protobuf/proto]
        [github.com/docker/spdystream github.com/docker/spdystream/spdy]
        [golang.org/x/text golang.org/x/text/cases golang.org/x/text/internal/tag golang.org/x/text/language golang.org/x/text/runes golang.org/x/text/secure/bidirule golang.org/x/text/secure/precis golang.org/x/text/transform golang.org/x/text/unicode/bidi golang.org/x/text/unicode/norm golang.org/x/text/width]
        [k8s.io/apimachinery/pkg/apimachinery k8s.io/apimachinery/pkg/apimachinery/announced k8s.io/apimachinery/pkg/apimachinery/registered]
        [google.golang.org/appengine google.golang.org/appengine/internal google.golang.org/appengine/internal/app_identity google.golang.org/appengine/internal/base google.golang.org/appengine/internal/datastore google.golang.org/appengine/internal/log google.golang.org/appengine/internal/modules google.golang.org/appengine/internal/remote_api]
        [golang.org/x/sys golang.org/x/sys/unix]
        [k8s.io/apimachinery/pkg/conversion k8s.io/apimachinery/pkg/conversion/queryparams]
        [golang.org/x/net golang.org/x/net/context golang.org/x/net/context/ctxhttp golang.org/x/net/http2 golang.org/x/net/http2/hpack golang.org/x/net/idna golang.org/x/net/lex/httplex]
        [github.com/davecgh/go-spew github.com/davecgh/go-spew/spew]
        [github.com/docker/distribution github.com/docker/distribution/digest github.com/docker/distribution/reference]
        [github.com/emicklei/go-restful github.com/emicklei/go-restful/log github.com/emicklei/go-restful/swagger]
        [k8s.io/apimachinery/pkg/apis/meta/v1 k8s.io/apimachinery/pkg/apis/meta/v1/unstructured]
        [k8s.io/apimachinery/pkg/runtime k8s.io/apimachinery/pkg/runtime/schema k8s.io/apimachinery/pkg/runtime/serializer k8s.io/apimachinery/pkg/runtime/serializer/json k8s.io/apimachinery/pkg/runtime/serializer/protobuf k8s.io/apimachinery/pkg/runtime/serializer/recognizer k8s.io/apimachinery/pkg/runtime/serializer/streaming k8s.io/apimachinery/pkg/runtime/serializer/versioning]
        [golang.org/x/crypto golang.org/x/crypto/ssh/terminal]

`vndr init` produces wrong `vendor.conf` for versioned packages

$ cat foo.go
package foo

import (
        "github.com/containerd/cgroups/v2"
)

func Foo(a, b string) (*v2.Manager, error) {
        return v2.LoadManager(a, b)
}
$ vndr init

Result:

github.com/containerd/cgroups/v2 3f83850c48d225466698517ad34f4848d2ddaeeb
github.com/containerd/cgroups/stats/v1 3f83850c48d225466698517ad34f4848d2ddaeeb
github.com/coreos/go-systemd d657f9650837651364841f00795b417b1ca43c1f
github.com/docker/go-units 519db1ee28dcc9fd2474ae59fca29a810482bfb1
github.com/godbus/dbus/v5 43c7e6d0673024b2dcdf97cb4d766efec9da7e9b
github.com/opencontainers/runtime-spec e09c7c488e298f2147734e657eba72fc9fa10ca9
github.com/pkg/errors 49f8f617296114c890ae0b7ac18c5953d2b1ca0f
golang.org/x/sys 548cf772de5052aa878ccb47cdeb7d262b75c8ec
github.com/coreos/go-systemd d657f9650837651364841f00795b417b1ca43c1f

Expected result:

github.com/containerd/cgroups 3f83850c48d225466698517ad34f4848d2ddaeeb
github.com/coreos/go-systemd/v22 d657f9650837651364841f00795b417b1ca43c1f
...

Note:

  • github.com/containerd/cgroups in vendor.conf MUST NOT contain /v2 suffix because v2 is a git subdirectory, not a version string in go.mod
  • github.com/coreos/go-systemd/v22 MUST contain /v22 suffix because v22 is a version string in go.mod, not a git subdirectory

I'm not sure how we can support this without parsing go.mod.

vndr version 0.1.0

Cross-tool config file

Hey there,

Trash author here :)

How about we agree on common config filename ("vndr.cfg" and "trash.conf" could stay as fallback), changing it to "vendor.conf", for example.

Then people could easily switch back and forth between vndr and trash tools.

Release

Hi @LK4D4. I'm currently packaging this for openSUSE, and it's a bit of a pain there's no version tags. Can you rectify that? Currently I'm doing something horrible with 0.0.0+r<num commits> as the version number...

panic cleaning up repository data when multiple deps specify a single sub-repo

I used this script to generate the deps for vndr from containers/image. What I believe is happening is that several goroutines are trying to update the same directory at the same time, which is causing your filepath.Walks to fail.

All the data that I have is in the ticket, I think.

#!/bin/bash

set -e

list() {
  (for i in $(go list $1 | xargs go list -f '{{ join .Deps "\n" }}' | grep -v github.com/containers/image | grep -v $GOPATH | sort | uniq)
  do
    if [ -d "$(go env GOROOT)/src/${i}" ]
    then
      continue
    else
      echo $i
    fi
  done) | sort | uniq
}

lastlist=""
echo 1>&2 -n Listing package...
mylist=$(list ./...)
echo 1>&2 done.

while [ "$lastlist" != "$mylist" ]
do
  # cancel out error mask below
  set -e
  lastlist=$mylist
  for i in $mylist
  do
    echo 1>&2 Processing deps for dependency "'$i'"

    if [ -d ${GOPATH}/src/${i} ]
    then
      continue
    else
      set +e
      go get -d $i
      if [ $? != 0 ]
      then
        # pad it to keep the loop running, we'll grep it out later.
        # the important thing is that we do not execute list here which will
        # break
        mylist=$(echo -e "$lastlist\n")
        continue
      fi
    fi

    echo 1>&2 -n Listing $i ...
    innerlist=$(list $i)
    echo 1>&2 done.
    mylist=$(echo -e "$lastlist\n$innerlist" | sort | uniq)
  done
done

echo 1>&2 Filtering dependency list...
(
for i in $mylist
do
  echo $i master
done
) | sort | uniq

panic on latest master:

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x20 pc=0x4051a5]

goroutine 50 [running]:
panic(0x701040, 0xc42000c100)
        /usr/local/go/src/runtime/panic.go:500 +0x1a1
main.cleanVCS.func1(0xc420061320, 0x59, 0x0, 0x0, 0x8b07c0, 0xc4205e0ff0, 0x0, 0x0)
        /home/erikh/src/github.com/lk4d4/vndr/clean.go:142 +0x35
path/filepath.walk(0xc420408900, 0x51, 0x8b6080, 0xc4206d6dd0, 0x7810b8, 0x0, 0xc420408a80)
        /usr/local/go/src/path/filepath/path.go:372 +0x22e
path/filepath.Walk(0xc420408900, 0x51, 0x7810b8, 0x0, 0x56)
        /usr/local/go/src/path/filepath/path.go:398 +0xd5
main.cleanVCS(0xc42038e3f0, 0x28, 0x0)
        /home/erikh/src/github.com/lk4d4/vndr/clean.go:153 +0x110
main.cloneDep(0xc420403d80, 0x32, 0xc42010eb70, 0x28, 0xc42010eb99, 0x6, 0x0, 0x0, 0x0, 0x0)
        /home/erikh/src/github.com/lk4d4/vndr/clone.go:101 +0x3c2
main.cloneAll.func1(0xc420061da0, 0xc420061d40, 0xc420403d80, 0x32, 0xc4203d05a0, 0xc42010eb70, 0x28, 0xc42010eb99, 0x6, 0x0, ...)
        /home/erikh/src/github.com/lk4d4/vndr/clone.go:71 +0x83
created by main.cloneAll
        /home/erikh/src/github.com/lk4d4/vndr/clone.go:74 +0x1ac

vendor.conf:

github.com/containers/storage/drivers/aufs master
github.com/containers/storage/drivers/btrfs master
github.com/containers/storage/drivers/devmapper master
github.com/containers/storage/drivers master
github.com/containers/storage/drivers/overlay2 master
github.com/containers/storage/drivers/overlay master
github.com/containers/storage/drivers/register master
github.com/containers/storage/drivers/vfs master
github.com/containers/storage/drivers/zfs master
github.com/containers/storage/pkg/archive master
github.com/containers/storage/pkg/chrootarchive master
github.com/containers/storage/pkg/devicemapper master
github.com/containers/storage/pkg/directory master
github.com/containers/storage/pkg/fileutils master
github.com/containers/storage/pkg/homedir master
github.com/containers/storage/pkg/idtools master
github.com/containers/storage/pkg/ioutils master
github.com/containers/storage/pkg/loopback master
github.com/containers/storage/pkg/mount master
github.com/containers/storage/pkg/parsers/kernel master
github.com/containers/storage/pkg/parsers master
github.com/containers/storage/pkg/pools master
github.com/containers/storage/pkg/promise master
github.com/containers/storage/pkg/random master
github.com/containers/storage/pkg/reexec master
github.com/containers/storage/pkg/stringid master
github.com/containers/storage/pkg/system master
github.com/containers/storage/storage master
github.com/containers/storage/storageversion master
github.com/docker/distribution/context master
github.com/docker/distribution/digestset master
github.com/docker/distribution master
github.com/docker/distribution/reference master
github.com/docker/distribution/registry/api/errcode master
github.com/docker/distribution/registry/api/v2 master
github.com/docker/distribution/registry/client/auth/challenge master
github.com/docker/distribution/registry/client master
github.com/docker/distribution/registry/client/transport master
github.com/docker/distribution/registry/storage/cache master
github.com/docker/distribution/registry/storage/cache/memory master
github.com/docker/distribution/uuid master
github.com/docker/distribution/vendor/github.com/gorilla/context master
github.com/docker/distribution/vendor/github.com/gorilla/mux master
github.com/docker/distribution/vendor/github.com/opencontainers/go-digest master
github.com/docker/distribution/vendor/github.com/Sirupsen/logrus master
github.com/docker/distribution/vendor/golang.org/x/net/context master
github.com/docker/engine-api/client master
github.com/docker/engine-api/client/transport/cancellable master
github.com/docker/engine-api/client/transport master
github.com/docker/engine-api/types/blkiodev master
github.com/docker/engine-api/types/container master
github.com/docker/engine-api/types/filters master
github.com/docker/engine-api/types master
github.com/docker/engine-api/types/mount master
github.com/docker/engine-api/types/network master
github.com/docker/engine-api/types/reference master
github.com/docker/engine-api/types/registry master
github.com/docker/engine-api/types/strslice master
github.com/docker/engine-api/types/swarm master
github.com/docker/engine-api/types/time master
github.com/docker/engine-api/types/versions master
github.com/docker/go-connections/nat master
github.com/docker/go-connections/sockets master
github.com/docker/go-connections/tlsconfig master
github.com/docker/go-units master
github.com/docker/libtrust master
github.com/ghodss/yaml master
github.com/golang/glog master
github.com/imdario/mergo master
github.com/mattn/go-runewidth master
github.com/mistifyio/go-zfs master
github.com/mtrmac/gpgme master
github.com/opencontainers/go-digest master
github.com/opencontainers/image-spec/specs-go master
github.com/opencontainers/image-spec/specs-go/v1 master
github.com/opencontainers/runc/libcontainer/label master
github.com/opencontainers/runc/libcontainer/system master
github.com/opencontainers/runc/libcontainer/user master
github.com/pborman/uuid master
github.com/pkg/errors master
github.com/Sirupsen/logrus master
github.com/vbatts/tar-split/archive/tar master
github.com/vbatts/tar-split/tar/asm master
github.com/vbatts/tar-split/tar/storage master
golang.org/x/net/context master
golang.org/x/net/http2/hpack master
golang.org/x/net/http2 master
golang.org/x/net/idna master
golang.org/x/net/lex/httplex master
golang.org/x/net/proxy master
gopkg.in/cheggaaa/pb.v1 master
gopkg.in/yaml.v2 master
k8s.io/apimachinery/pkg/util/errors master
k8s.io/apimachinery/pkg/util/net master
k8s.io/apimachinery/pkg/util/sets master
k8s.io/kubernetes/pkg/util/homedir master

vndr command doesn't work

I used /Users/chenminjian/dev/go_pack/bin/vndr command to download package in my work dir,but I didn't find any package in my vendor folder.
------my log-------
2017/03/23 13:17:33 Collecting initial packages
2017/03/23 13:17:33 Download dependencies
2017/03/23 13:17:33 Clone github.com/spf13/pflag, revision 9ff6c6923cfffbcd502984b8e0c80539a94968b7
2017/03/23 13:17:33 Clone https://github.com/dnephin/cobra.git to github.com/spf13/cobra, revision v1.5.1
2017/03/23 13:17:40 Finished clone github.com/spf13/pflag
2017/03/23 13:17:44 Finished clone github.com/spf13/cobra
2017/03/23 13:17:44 Dependencies downloaded. Download time: 11.000047077s
2017/03/23 13:17:44 Collecting all dependencies
2017/03/23 13:17:44 Clean vendor dir from unused packages
2017/03/23 13:17:44 Success
2017/03/23 13:17:44 Running time: 11.009391968s

Dot imports (Ginkgo) are ignored

Dot imports are ignored, reproduce with test below:

main

package main

import (
	"fmt"

	. "github.com/onsi/ginkgo"
)

func main() {
	fmt.Println("bug")
}

vendor.conf

github.com/onsi/ginkgo master

@LK4D4 PTAL

cache cloned git repositories

Running vndr with a vendor.conf which contains some large repositories can take quite some time to clone them all every time. This is particularly apparent when iterating adding transitive dependencies of a new package (or today when github is glitchy meaning at least one clone is bound to fail).

It'd be great if vndr could keep a cache of the repositories it has cloned and try to update them rather than reclone every time.

My preference would be to keep the cache in $XDG_CACHE_HOME/vndr (where $XDG_CACHE_HOME defaults to $HOME/.cache) so my existing backup rules will ignore the cache.

Does not cleanup vendoring not referenced by `vendor.conf` if it is used

moby/buildkit@e8dbd3a has a bug where the package github.com/morikuni/aec is not present in vendor.conf (it was accidentally dropped) but is used by the code and remains in vendor/ after running vndr.

I would expect an error or at least a warning (which could be turned into an error with -strict, nb #62 might have an effect).

If I rm -rf vendor && vndr then the check done in ./hack/validate-vendor does complain:

[...]
2018/03/08 14:39:04 	WARNING(verbose) github.com/morikuni/aec: cannot find package "github.com/morikuni/aec" in any of:
	/go/src/github.com/moby/buildkit/vendor/github.com/morikuni/aec (vendor tree)
	/go/src/github.com/moby/buildkit/vendor/github.com/morikuni/aec
	/usr/local/go/src/github.com/morikuni/aec (from $GOROOT)
	/go/src/github.com/morikuni/aec (from $GOPATH)
[...]
The result of vndr differs

 D vendor/github.com/morikuni/aec/LICENSE
 D vendor/github.com/morikuni/aec/README.md
 D vendor/github.com/morikuni/aec/aec.go
 D vendor/github.com/morikuni/aec/ansi.go
 D vendor/github.com/morikuni/aec/builder.go
 D vendor/github.com/morikuni/aec/sgr.go

Please vendor your package with github.com/LK4D4/vndr.

(without my rm -rf vendor the result can be seen here, which exhibits #62 as well)

Latest patches break older apps

Although it's not perfect, my Go app used to compile properly with commit b57c5799efd5ed743f347a025482babf01ba963e and below.
As of the latest patches, it seems that all vendor folders are removed.

The output of vndr was:

bash-4.3# ls
main.go      vendor       vendor.conf
bash-4.3# vndr
2018/03/29 18:10:47 Collecting initial packages
2018/03/29 18:10:47 Download dependencies
2018/03/29 18:10:47 	Clone github.com/jehiah/go-strftime, revision 2efbe75097a505e2789f7e39cb9da067b5be8e3e
2018/03/29 18:10:47 	Clone github.com/xtgo/uuid, revision a0b114877d4caeffbd7f87e3757c17fce570fea7
2018/03/29 18:10:47 	Clone github.com/segmentio/analytics-go, revision bdb0aeca8a993b292b85c9ec17b5ce0ff81848c8
2018/03/29 18:10:47 	Clone github.com/segmentio/backo-go, revision 204274ad699c0983a70203a566887f17a717fef4
2018/03/29 18:10:48 	Finished clone github.com/jehiah/go-strftime
2018/03/29 18:10:48 	Finished clone github.com/xtgo/uuid
2018/03/29 18:10:48 	Finished clone github.com/segmentio/analytics-go
2018/03/29 18:10:48 	Finished clone github.com/segmentio/backo-go
2018/03/29 18:10:48 Dependencies downloaded. Download time: 666.5187ms
2018/03/29 18:10:48 Collecting all dependencies
2018/03/29 18:10:48 Clean vendor dir from unused packages
2018/03/29 18:10:48 Success
2018/03/29 18:10:48 Running time: 826.3041ms

Since then the build will fail, as all vendor packages are removed.
The output is:

bash-4.3# ls
main.go      vendor       vendor.conf
bash-4.3# vndr
2018/03/29 18:13:21 Collecting initial packages
2018/03/29 18:13:21 Download dependencies
2018/03/29 18:13:21 Starting whole vndr cycle because no package specified
2018/03/29 18:13:21 	Clone github.com/xtgo/uuid, revision a0b114877d4caeffbd7f87e3757c17fce570fea7
2018/03/29 18:13:21 	Clone github.com/segmentio/analytics-go, revision bdb0aeca8a993b292b85c9ec17b5ce0ff81848c8
2018/03/29 18:13:21 	Clone github.com/jehiah/go-strftime, revision 2efbe75097a505e2789f7e39cb9da067b5be8e3e
2018/03/29 18:13:21 	Clone github.com/segmentio/backo-go, revision 204274ad699c0983a70203a566887f17a717fef4
2018/03/29 18:13:21 	Finished clone github.com/jehiah/go-strftime
2018/03/29 18:13:21 	Finished clone github.com/xtgo/uuid
2018/03/29 18:13:22 	Finished clone github.com/segmentio/analytics-go
2018/03/29 18:13:22 	Finished clone github.com/segmentio/backo-go
2018/03/29 18:13:22 Dependencies downloaded. Download time: 612.7808ms
2018/03/29 18:13:22 Collecting all dependencies
2018/03/29 18:13:22 Clean vendor dir from unused packages
2018/03/29 18:13:22 WARNING: package github.com/jehiah/go-strftime is unused, consider removing it from vendor.conf
2018/03/29 18:13:22 WARNING: package github.com/segmentio/analytics-go is unused, consider removing it from vendor.conf
2018/03/29 18:13:22 WARNING: package github.com/segmentio/backo-go is unused, consider removing it from vendor.conf
2018/03/29 18:13:22 WARNING: package github.com/xtgo/uuid is unused, consider removing it from vendor.conf
2018/03/29 18:13:22 Success
2018/03/29 18:13:22 Running time: 643.4008ms

vendor.conf:

bash-4.3# cat vendor.conf
github.com/jehiah/go-strftime 2efbe75097a505e2789f7e39cb9da067b5be8e3e
github.com/segmentio/analytics-go bdb0aeca8a993b292b85c9ec17b5ce0ff81848c8
github.com/segmentio/backo-go 204274ad699c0983a70203a566887f17a717fef4
github.com/xtgo/uuid a0b114877d4caeffbd7f87e3757c17fce570fea7

My main.go imports are:

        "flag"
	"github.com/user/repo/some/path/pkg/app"
	"os"
	"regexp"
	"strings"

github.com/user/repo/some/path/pkg/app main.go imports:

	"crypto/hmac"
	"crypto/sha256"
	"encoding/base64"

	"github.com/segmentio/analytics-go"

Using the commit mentioned above, the tree looks like this:

bash-4.3# tree vendor
vendor
โ””โ”€โ”€ github.com
    โ”œโ”€โ”€ user
    โ”‚ย ย  โ””โ”€โ”€ repo
    โ”‚ย ย      โ””โ”€โ”€ some
    โ”‚ย ย          โ””โ”€โ”€ path
    โ”‚ย ย              โ””โ”€โ”€ pkg
    โ”‚ย ย                  โ””โ”€โ”€ app
    โ”‚ย ย                      โ””โ”€โ”€ main.go
    โ”œโ”€โ”€ jehiah
    โ”‚ย ย  โ””โ”€โ”€ go-strftime
    โ”‚ย ย      โ”œโ”€โ”€ LICENSE
    โ”‚ย ย      โ”œโ”€โ”€ README.md
    โ”‚ย ย      โ””โ”€โ”€ strftime.go
    โ”œโ”€โ”€ segmentio
    โ”‚ย ย  โ”œโ”€โ”€ analytics-go
    โ”‚ย ย  โ”‚ย ย  โ”œโ”€โ”€ Readme.md
    โ”‚ย ย  โ”‚ย ย  โ””โ”€โ”€ analytics.go
    โ”‚ย ย  โ””โ”€โ”€ backo-go
    โ”‚ย ย      โ”œโ”€โ”€ README.md
    โ”‚ย ย      โ””โ”€โ”€ backo.go
    โ””โ”€โ”€ xtgo
        โ””โ”€โ”€ uuid
            โ”œโ”€โ”€ LICENSE
            โ””โ”€โ”€ uuid.go

14 directories, 10 files

The binary is built within a Golang:1.7-alpine container.
The github.com/user/repo/some/path/pkg/app is copied into the vendor folder during build time within the vendor folder: /go/src/myapp/vendor/github.com/user/repo/some/path/pkg/app

vndr sometimes fails when cloning large repos

Hi,

I recently noticed that vndr may sometime fails when cloning large repos.
In my case, I'm depending on https://github.com/fsouza/go-dockerclient, which in turn depends on Docker's code itself, for which clones fails quite often with the following error:

github.com/docker/docker: Err: exit status 128, out: Cloning into '/home/pdalpra/Work/golang/src/github.com/mycompany/myproject/vendor/github.com/docker/docker'...
error: index-pack died of signal 25
fatal: index-pack failed

WDYT of doing shallow clones when vendoring deps from Git repos ? As this would clone only the very last commit (which IMHO is acceptable for vendored dependencies), this may solve this issue and possibly speed up the cloning of repositories.

Latest vndr picks up lots more stuff (due to .c file inclusion)

Rerunning vndr on containerd with the latest version picked up a lot of extra stuff, I think because of #69/#70. Is this expected or is it going further than was intended?

See containerd/containerd@623407a which has stat of:

vendor/github.com/docker/docker/contrib/README.md             |    4 +
 vendor/github.com/docker/docker/contrib/nnp-test/nnp-test.c   |   10 +
 vendor/github.com/docker/docker/contrib/syscall-test/acct.c   |   16 +
 vendor/github.com/docker/docker/contrib/syscall-test/exit32.s |    7 +
 vendor/github.com/docker/docker/contrib/syscall-test/ns.c     |   63 ++++
 vendor/github.com/docker/docker/contrib/syscall-test/raw.c    |   14 +
 vendor/github.com/docker/docker/contrib/syscall-test/setgid.c |   11 +
 vendor/github.com/docker/docker/contrib/syscall-test/setuid.c |   11 +
 vendor/github.com/docker/docker/contrib/syscall-test/socket.c |   30 ++
 vendor/github.com/docker/docker/contrib/syscall-test/userns.c |   63 ++++
 vendor/golang.org/x/crypto/otr/libotr_test_helper.c           |  197 +++++++++++
 vendor/golang.org/x/crypto/otr/otr.go                         | 1415 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 vendor/golang.org/x/crypto/otr/smp.go                         |  572 ++++++++++++++++++++++++++++++++
 vendor/golang.org/x/crypto/ssh/test/doc.go                    |    7 +
 vendor/golang.org/x/crypto/ssh/test/sshd_test_pw.c            |  173 ++++++++++
 vendor/golang.org/x/sys/windows/svc/event.go                  |   48 +++
 vendor/golang.org/x/sys/windows/svc/go12.c                    |   24 ++
 vendor/golang.org/x/sys/windows/svc/go12.go                   |   11 +
 vendor/golang.org/x/sys/windows/svc/go13.go                   |   31 ++
 vendor/golang.org/x/sys/windows/svc/security.go               |   62 ++++
 vendor/golang.org/x/sys/windows/svc/service.go                |  363 +++++++++++++++++++++
 vendor/golang.org/x/sys/windows/svc/sys_386.s                 |   68 ++++
 vendor/golang.org/x/sys/windows/svc/sys_amd64.s               |   42 +++
 vendor/k8s.io/kubernetes/build/README.md                      |  110 +++++++
 vendor/k8s.io/kubernetes/build/pause/orphan.c                 |   36 ++
 vendor/k8s.io/kubernetes/build/pause/pause.c                  |   68 ++++
 26 files changed, 3456 insertions(+)

strict mode does not fail for "cannot find package" error

I noticed that a project (moby/buildkit as it happens) was missing a dependency (you can see it here). I patched the check (./hack/validate-vendor and hack/dockerfiles/vendor.Dockerfile) thinking it would cause the check to fail but it did not:

$ git diff
diff --git a/hack/dockerfiles/vendor.Dockerfile b/hack/dockerfiles/vendor.Dockerfile
index 64cd656..ac82dfe 100644
--- a/hack/dockerfiles/vendor.Dockerfile
+++ b/hack/dockerfiles/vendor.Dockerfile
@@ -7,4 +7,4 @@ RUN go get -d github.com/LK4D4/vndr \
        && go install ./
 WORKDIR /go/src/github.com/moby/buildkit
 COPY . .
-RUN vndr --verbose
\ No newline at end of file
+RUN vndr --verbose --strict
[...]
$ ./hack/validate-vendor 
[...]
+ docker build --build-arg VNDR_VERSION=48ac2669d9d1bcacd3163650ef911edca2ec3b42 --iidfile /tmp/docker-iidfile.9obqMoTlAJ -f ./hack/dockerfiles/vendor.Dockerfile --force-rm .
[...]Step 7/7 : RUN vndr --verbose --strict
 ---> Running in 1c252b10149d
2018/03/08 14:26:15 Collecting initial packages
2018/03/08 14:26:15 Download dependencies
[...]
2018/03/08 14:27:11 Dependencies downloaded. Download time: 55.205977209s
2018/03/08 14:27:11 Collecting all dependencies
2018/03/08 14:27:13 	WARNING(verbose) github.com/tonistiigi/llb-gobuild: cannot find package "github.com/tonistiigi/llb-gobuild" in any of:
	/go/src/github.com/moby/buildkit/vendor/github.com/tonistiigi/llb-gobuild (vendor tree)
	/go/src/github.com/moby/buildkit/vendor/github.com/tonistiigi/llb-gobuild
	/usr/local/go/src/github.com/tonistiigi/llb-gobuild (from $GOROOT)
	/go/src/github.com/tonistiigi/llb-gobuild (from $GOPATH)
2018/03/08 14:27:14 Clean vendor dir from unused packages
2018/03/08 14:27:14 Success
2018/03/08 14:27:14 Running time: 59.498826306s
Removing intermediate container 1c252b10149d
 ---> cf2f4a83aad9
Successfully built cf2f4a83aad9
++ cat /tmp/docker-iidfile.9obqMoTlAJ
+ iid=sha256:cf2f4a83aad9c24e1e16e2ff5dc6fde8265d4872dbe1f6f91cc12bb7abded0e1
++ docker run sha256:cf2f4a83aad9c24e1e16e2ff5dc6fde8265d4872dbe1f6f91cc12bb7abded0e1 git status --porcelain -- vendor
+ diffs=
+ '[' '' ']'
+ echo 'Congratulations! All vendoring changes are done the right way.'
Congratulations! All vendoring changes are done the right way.
+ rm -f /tmp/docker-iidfile.9obqMoTlAJ

I think this should have failed.

The above is with 48ac266 but I have also reproduced with b57c579 which is the most recent master.

In fact with the most recent master it seems the WARNING has gone, even though llb-gobuild is still used -- the usage is in a example command (so a main package, but a few levels down in the source tree) so perhaps that got missed?

Possible vendor.conf syntax to allow use of tags without downsides of retagging

In moby/swarmkit#2220 I proposed moving some vendoring from using hashes to using tagged releases, however it was pointed out that this is vulnerable to (possibly even malicious) retagging by upstreams.

@thaJeztah proposed that maybe it would be possible to introduce a syntax such as vX.Y.Z@SHA to get the benefits of tagging (such as being human readable and orderable) without the downside of losing control over the specific version.

I wasn't sure if this was possible, since AFAIK the syntax of vendor.conf is common to several tools, but thought we could at least discuss it here since vndr is the tool being used (if there is a more appropriate tool neutral venue for such discussions then I'm happy to move this there).

Not quite sure of the expected semantics of the vX.Y.Z@SHA syntax, obviously it should checkout of SHA, but perhaps it should also validate that vX.Y.Z points to that commit and error out if not, or maybe the vX.Y.Z is purely informational, I don't know (although if it is only informational it could just as well be a comment).

For SHA which is not a tagged release we could consider allowing the vX.Y.Z to actually be a git describe --tags SHA output, which indicates how the commit relates to some recent tag, that's nice because you can see "oh this is a couple of commits after a release" etc. Although I'm not 100% sure it is deterministic over git versions or if there is an easy mechanism to check for correspondence (in either direction).

vndr command not found

I installed vndr as described in the description of the repo but vndr kept on giving me command not found.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.