Search code examples
goterminology

What does "vendoring" mean in Go?


When learning about Go's dependency management, I often hear the term "vendor" used as a verb. Example: "The dependencies that your application vendors..."

What does it mean to vendor a dependency in this context?


Examples:

"Dependencies that are vendored with your application"

Source: https://devcenter.heroku.com/articles/getting-started-with-go#declare-app-dependencies

"godep will write the vendored code"

Source: https://github.com/tools/godep#go-15-vendor-experiment


Follow-up questions:


Solution

  • Defined here for Go as:

    Vendoring is the act of making your own copy of the 3rd party packages your project is using. Those copies are traditionally placed inside each project and then saved in the project repository.

    I don't know squirt about Ruby.

    Essentially you're taking a package, storing it within your own project and using that version to build from. I liken it to how you might have a "vendors" folder where you put third party css or js when building a web page.