Questions tagged [go-get]

Go-get downloads the packages named by the import paths, along with their dependencies. It then installs the named packages, like 'go install'.

80 questions
15
votes
3 answers

Why does go get fail with "invalid version: unknown revision"?

I published an update to a Go module, bumping the version to v1.1.0. I created a tag named v1.1.0 and pushed the tag to GitHub. https://github.com/depp/bytesize/releases/tag/v1.1.0 However, I cannot use this package in my other projects. I get an…
Dietrich Epp
  • 205,541
  • 37
  • 345
  • 415
12
votes
3 answers

Go Get for Google's Cloud Source Repository

Making two different go modules source.cloud.google.com/me/a source.cloud.google.com/me/b With source.cloud.google.com/me/common as a common lib dependency (to share a model) I'm trying to go get source.cloud.google.com/me/common (even manually…
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
7
votes
1 answer

go get doesn't work with .gitconfig that references a custom gitconfig

I clone a repository with git clone which has a dependency from another private repo. Inside current repo I try to go get that dependency (go get -u ./...) and it throws me an error: fatal: could not read Username for 'https://bitbucket.org':…
Klimbo
  • 1,308
  • 3
  • 15
  • 34
6
votes
1 answer

Get a private repository from AWS codecommit using HTTPS GRC

I'm trying to import a module located in AWS codecommit. To clone the repository I'm using HTTPS GRC (Git Remote Codecommit) method, which uses Google Suite credentials to access AWS console. The command I use to clone the repository is: git clone…
Ortzi
  • 363
  • 1
  • 6
  • 17
4
votes
1 answer

go get PRIVATE repo with proxy

My company provides a VPN, but only a global proxy, so I started a vpn in docker and provided the sock5 proxy to the outside, and I wanted go get ≈ use my locally started sock5 proxy. my configuration file - Go env ```…
Mashiro
  • 86
  • 5
4
votes
1 answer

How to prevent go get from updating go.mod file

TL;DR: Is there any way I can forcefully prevent go get from altering the go.mod file? When I do a go get of certain packages, e.g.: $ go get github.com/AsynkronIT/protoactor-go/protobuf/protoc-gen-gograin It will printout that it has updated…
Filipe Freire
  • 823
  • 7
  • 21
4
votes
3 answers

How can you specify which ssh key `go get` will use

I'm using two different github accounts (personal and work) on the same laptop (running Ubuntu version 20). I need to be able to access private repos from work using the ssh key for my work github account. I've made it all work using some neat git…
gloriphobia
  • 1,423
  • 13
  • 21
4
votes
4 answers

Go get private bitbucket repo giving 403 forbidden

On execution of go get bitbucket.org/../.. I get this error yash.jain projectname % go get bitbucket.org/../.. go: bitbucket.org/../.. https://api.bitbucket.org/2.0/repositories/../..?fields=scm: 403 Forbidden go: error loading module…
yashjain12yj
  • 723
  • 7
  • 19
4
votes
1 answer

Some issues with `go get cloud.google.com/go/cloudtasks/apiv2`; undefined: grpc.RoundRobin

The subject in question: https://cloud.google.com/tasks/docs/creating-http-target-tasks?hl=ru Programming language: GO First, download this package: go get -u google.golang.org/genproto/googleapis/cloud/tasks/v2 No problem. Next I download this…
3
votes
1 answer

How to make go get work for golang.org when behind corporate firewall

First of all, although it looks the same as the following questions How to fix git error: RPC failed; curl 56 GnuTLS git error:RPC failed,curl 56 GnuTLS recv error (-110), and "error: RPC failed; curl 56 GnuTLS recv error (-110): The TLS connection…
xpt
  • 20,363
  • 37
  • 127
  • 216
3
votes
1 answer

Go get error while getting major version module dependency

I have an executable go module and i am trying to execute the below command go get github.com/saipraveen-a/number-manipulation/v2 and get this error: module github.com/saipraveen-a/number-manipulation@upgrade found (v1.0.1), but does not contain…
java_geek
  • 17,585
  • 30
  • 91
  • 113
3
votes
2 answers

go get a private repo from codecommit

I'm new to golang, we are trying to create a package in go and use across all the services we wanted to use. I tried to create a repo in github and tried to do go get; I didn't get any issue. Now I wanted to create the same package in codecommit of…
Sreenath
  • 480
  • 2
  • 6
  • 17
2
votes
0 answers

Go get errors "could not read from remote repository"

Using "go get", I enter this command: go get github.com/company/code The repository is private. The error that comes back says this: go get: module github.com/company/code: git ls-remote -q origin in…
Brent
  • 805
  • 9
  • 20
2
votes
1 answer

'go get' from bitbucket with two different bitbucket account

#1 I followed some articles on how to access github or bitbucket with two different ssh keys, and it works fine when I do a git clone .... So, I can do a git clone git://git@github.com/... and git clone git://git@mycompany-bitbucket.org/... without…
haalcala
  • 63
  • 5
1
2 3 4 5 6