Go package problem on GitLab

This happens on Golang from version 1.13. I verify this after reading this https://golang.org/doc/go1.13#modules

Problem

go get -u gitlab.com/fast-and-comfy/internal
# cd .; git clone -- https://gitlab.com/fast-and-comfy/internal.git /Users/pepa/go/src/gitlab.com/fast-and-comfy/system
Cloning into '/Users/pepa/go/src/gitlab.com/fast-and-comfy/system'...
fatal: could not read Username for 'https://gitlab.com': terminal prompts disabled
package gitlab.com/fast-and-comfy/system: exit status 128

Fix

git config --global url."git@gitlab.com:".insteadOf"https://gitlab.com/"

Problem 2

go build
go: finding gitlab.com/fast-and-comfy/lib latest
go: finding gitlab.com/fast-and-comfy/lib/log latest
go: downloading gitlab.com/fast-and-comfy/lib v0.0.0-20191226192620-45cc938f491c
verifying gitlab.com/fast-and-comfy/lib@v0.0.0-20191226192620-45cc938f491c: gitlab.com/fast-and-comfy/lib@v0.0.0-20191226192620-45cc938f491c: reading https://sum.golang.org/lookup/gitlab.com/fast-and-comfy/lib@v0.0.0-20191226192620-45cc938f491c: 410 Gone

Fix

Using GOPRIVATE

The new GOPRIVATE environment variable indicates module paths that are not publicly available. It serves as the default value for the lower-level GONOPROXY and GONOSUMDB variables, which provide finer-grained control over which modules are fetched via proxy and verified using the checksum database.

Put in ~/.zshrc

# repos list divided comma
export GOPRIVATE="gitlab.com/fast-and-comfy/lib/log,github.com....."

Using GONOSUMDB

# repos list divided comma
export GONOSUMDB="gitlab.com/fast-and-comfy/lib/log,github.com....."