Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Golang GVM 修改国内镜像

使用 GVM 安装不同版本的 Go。碰到问题是国内无法访问 GVM 配置的源地址。报如下错误:

$ gvm install go1.8
Downloading Go source...
Installing go1.8...
 * Compiling...
ERROR: Couldn't download Go source. Check the logs /root/.gvm/logs/go-download.log
$ cat /root/.gvm/logs/go-download.log
Initialized empty Git repository in /root/.gvm/archive/go/.git/
error: Failed connect to; Operation now in progress while accessing

fatal: HTTP request failed
Initialized empty Git repository in /root/.gvm/archive/go/.git/
Initialized empty Git repository in /root/.gvm/archive/go/.git/

国内访问不了 可将 GO_SOURCE_URL修改为github上的源码镜像


vim ~/.gvm/scripts/install



This comment has been minimized.

Copy link

commented Mar 1, 2019

gvm listall 命令也可以改成git的地址,多谢

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.