比如安装下面第三方包
C:\Users\xxx>go get github.com/denisenkom/go-mssqldb
go get github.com/denisenkom/go-mssqldb: module github.com/denisenkom/go-mssqldb: Get "https://proxy.golang.org/github.com/denisenkom/go-mssqldb/@v/list": dial tcp 172.217.24.17:443: connectex: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.
或vscode安装下面的失败
Installing 8 tools at D:\GoPath\bin
go-outline
go-symbols
guru
gorename
dlv
godef
goreturns
golint
Installing golang.org/x/tools/cmd/guru FAILED
Installing github.com/ramya-rao-a/go-outline FAILED
Installing golang.org/x/tools/cmd/gorename FAILED
Installing github.com/derekparker/delve/cmd/dlv SUCCEEDED
Installing github.com/acroca/go-symbols FAILED
Installing golang.org/x/tools/cmd/guru FAILED
Installing github.com/rogpeppe/godef SUCCEEDED
Installing golang.org/x/tools/cmd/gorename FAILED
Installing github.com/derekparker/delve/cmd/dlv SUCCEEDED
Installing github.com/rogpeppe/godef SUCCEEDED
Installing github.com/sqs/goreturns FAILED
Installing github.com/golang/lint/golint FAILED
解决方法
- 从GitHub上clone下来安装
- 最省事的:改GOPROXY代理环境变量为https://goproxy.cn,或其他代理地址
|
请发表评论