go get 下载慢 失败 解决方案

使用代理加快go get 速度。
https://goproxy.io/ 提供了go get 代理。
使用mac/linux的用户,在对应终端配置文件添加以下代码即可解决上述问题。
vim ~/.zshrcvim ~/.bashrc

# Enable the go modules feature
export GO111MODULE=on
# Set the GOPROXY environment variable
export GOPROXY=https://goproxy.io
发布了60 篇原创文章 · 获赞 0 · 访问量 1420

猜你喜欢

转载自blog.csdn.net/ClassmateLin/article/details/100637685