Questions tagged [govendor]
56 questions
46
votes
3 answers
How do I migrate from Dep to Go Modules
I'm currently using Dep and would like to start using Go modules.
How do I migrate?

Nic
- 12,220
- 20
- 77
- 105
24
votes
3 answers
What are the benefits of having a vendor folder?
I can't really grasp the purpose of having a vendor folder. Based on what I learned, it seems the vendor folder is only beneficial if you're trying to make your repo compatible with golang versions earlier than 1.11. We are running golang…

Daniel Kobe
- 9,376
- 15
- 62
- 109
8
votes
3 answers
Build error in Go/Golang: Column does not implement gorm.ColumnType (missing AutoIncrement method)
I am facing this build error in Golang V1.17 intermittently.
# gorm.io/driver/mysql
../../../../pkg/mod/gorm.io/driver/mysql@v1.2.1/migrator.go:224:24: cannot use column (type Column) as type gorm.ColumnType in append:
Column does not…

Ranjith Muniyappa
- 81
- 1
- 4
8
votes
2 answers
How to use 'go get' or 'go mod vendor' for a specific module, without trying to update other modules?
I'm trying to get a specific package from github for a project.
However, when I use go get [url] or go mod vendor, I get a git fetch error for lack of permissions to one of my company's repos. This repo is vendored, which is how we get around it for…

ozma
- 349
- 1
- 3
- 10
5
votes
3 answers
What does "inconsistent vendoring" mean in Go?
I'm getting this inconsistent vendoring error and I'm a total Go newbie. Can anyone explain to me how go.mod interacts with vendor/modules.txt? I found this question helpful, and now I'm wondering if I should even have a vendor directory. Would that…

Bee
- 195
- 1
- 3
- 12
5
votes
1 answer
Does govendor automatically include transitive dependencies?
Let's say I add a new dependency X through govendor add or govendor fetch. This dependency X has a dependency on Y.
Will govendor automatically pull in those dependencies as well? Or will I have to do govendor add Y.
Does the behavior differ…

stephenbez
- 5,598
- 3
- 26
- 31
4
votes
2 answers
Go modules and dependencies with modified vendors
I am trying to convert one Go project to the new modules standard, but I am having trouble with one dependency.
That repository has vendored a library (in this case golang.org/x/net/html) to add some functionality to the library; meaning that it has…

AntonioHS
- 1,360
- 10
- 25
4
votes
3 answers
govendor doesn't work from cmd
I try to use govendor in my project folder /d/projects/go/src/github.com/user/dbot
govendor init
but bash returns
bash: govendor: command not found
for installation I just follow instruction and use
go get -u github.com/kardianos/govendor
there…

rjxby
- 53
- 1
- 1
- 6
3
votes
1 answer
Go 1.11 ignores the `vendor` directory, the errors give the impression the directory is never even looked at
I'm having the issue of Go 1.11.4 ignoring the vendor directory of the project I'm in.
When trying to run various commands, I get the following errors, even though the paths referenced are clearly present in the vendor directory. The error message…

cnst
- 25,870
- 6
- 90
- 122
3
votes
2 answers
How to work with a development vendor package managed by dep?
How can I use a development copy/clone of a package while using dep and a vendor directory? The vendor directory is included in the main repository.
For example, I have forked package and replaced it with my own on github. I want to be able to edit…

gak
- 32,061
- 28
- 119
- 154
3
votes
3 answers
docker-compose cannot find package
I'm writing a simple app in GO and I have this folder structure
The docker-compose.yml file content is:
version: '2'
services:
db:
image: rethinkdb:latest
ports:
- "38080:8080"
- "38015:28015"
- "39015:29015"
api:
…

utiq
- 1,342
- 2
- 17
- 33
2
votes
1 answer
Upgrading old go project to work with go modules
My $GOPATH contains 3 locations
/home//Documents/gotree
/home//Documents/perforce/modules/thirdparty/golibs
/home//Documents/perforce/modules/sggolibs/
Here location 1 is for general purposes, 2 and 3 for work-related libraries, which are…

Renju Ashokan
- 428
- 6
- 18
2
votes
2 answers
How do I remove unused dependencies with govendor
I want to cleanup my vendor folder in my golang project. What is the best way to go about this?

Aki
- 3,709
- 2
- 29
- 37
2
votes
1 answer
golang vendor path cannot find package
I'm building the example program from github.com/tarm/serial.
Case 1: It builds ok if the above repo is checked out into $GOPATH/src/github.com/tarm/serial.
Case 2: If the repo is moved under $GOPATH/src/vendor/github.com/tarm/serial the go build…

minghua
- 5,981
- 6
- 45
- 71
2
votes
2 answers
Google Cloud Container Builder - Build Docker container from Go source with vendored dependencies
Background
Related question: Google Container Builder: How to install govendor dependencies during build step?
I am trying to use Google Cloud Container Builder to automate the building of my Docker containers using Build Triggers.
My code is in Go,…

Ismail Khan
- 842
- 2
- 8
- 20