-
Notifications
You must be signed in to change notification settings - Fork 80
Conversation
0a5481e
to
e3cb044
Compare
Why do you not want to vendor the deps? Derek Gonyeo [email protected] schrieb am Fr., 26. Feb. 2016 20:23:
|
It's not something that's as nicely supported with glide. It leaves the .git directories in what it fetches, and I didn't see an easy way to disable that. I see two arguments to not want to move away from vendoring our dependencies:
I also think that glide's model will make it a good amount easier to work on both acbuild and one of acbuild's dependencies concurrently, since you can just |
3c87949
to
e049a6a
Compare
Hi, as I also started experimenting with glide, I'd like to share what I learned since I'd prefer to vendor dependencies:
http://engineeredweb.com/blog/2016/glide-strip-vendor-vcs/
http://engineeredweb.com/blog/2016/go-why-not-strip-unused-pkgs/ But if you are sure of not causing license issues you can probably write a tool (I'm going to do this if it doesn't exists) that, given the glide.lock will remove all the files outside the import or subpackages (if the import have sub packages).
But this is a problem present also with old style Godep vendoring/rewriting. |
@sgotti thanks for letting us know your experience! Would you mind sharing On Thu, Mar 3, 2016 at 9:46 PM, Simone Gotti [email protected]
|
@jonboulle sure. I'm currently not in the position to suggest a tool over another. I was intrigued on how it tries to manage dependencies like npm, pip, bundler using a config file and lock files, it tries to implements semver dependencies and read config from other vendor tools like godeps, gb etc... Obviously, since golang is really distributed and doesn't have a central repository, there are some differences with other languages/tools. One interesting thing is that it doesn't needs packages in your gopath but it will check them out directly inside your project (or copy them from a cache dir or from the gopath and then checking out the right version inside you project). On the other side, glide doesn't enforce you to commit your vendor directory. This is causing me some headache since many projects (myself too) wants to commit it (for a lot of good reasons), but having or not having nested vendor directories have a different compilation behavior. I opened Masterminds/glide#303 to talk about this. Additionally, if I want to commit, and I'm sure to not cause licenses violations, I'd like to remove as much as possible from the vendor directory. I wrote a tool to do this (https://github.com/sgotti/glide-vc) (with some changes in flight, see the opened PRs) |
After triggering some discussions on Masterminds/glide#303, glide 0.10 has much improved the vendor handling (http://engineeredweb.com/blog/2016/glide-0.10.0/) Now you can easily remove nested vendor folders. This obviously means that you won't have problems like this but you can't have multiple versions of the same package (since all deps are flattened). So if you have two dependencies that depends on incompatible version of actually my preferred workflow is this one:
|
cross-linking sorintlab/stolon#131 |
f89dcb5
to
b06b19a
Compare
Revisited this, tests now pass. Now vendors dependencies, unlike when I originally made this PR (uses glide flags to trip VCS info). Added |
Oh, and due to switching to using |
@dgonyeo there is a tonne of unused stuff in there - is this post- |
bd14fc4
to
d47261f
Compare
No it's not. Just ran |
Godep was continually being a drain on development resources of acbuild,
and thus this commit replaces godep with glide. Glide takes advantage of
the golang vendor experiment, and thus this change will drop support for
versions of Go less than 1.5.
The biggest impact this change has is that dependencies are no longer
vendored with acbuild, and are instead fetched at compile time by the
build script. This is done by checking if the
vendor
directory exists,and running
glide install
if it is not.Fixes #98. Replaces #157.