問題
使用 glide install
或 glide up
時報 Cannot detect VCS
解決
這個是國內(nèi)訪問golang.org
被墻導(dǎo)致的
解決方法如下:
glide mirror set https://golang.org/x/crypto https://github.com/golang/crypto
理論上這樣后再執(zhí)行 glide install
或 glide up
就可以了
- 如果按上面方式還不行的話萨脑,嘗試如下方法:
rm -rf ~/.glide
mkdir -p ~/.glide
glide mirror set https://golang.org/x/crypto https://github.com/golang/crypto
- 有可能你的是下面的鏈接槽地,用到哪個執(zhí)行哪個就好
glide mirror set https://golang.org/x/mobile https://github.com/golang/mobile --vcs git
glide mirror set https://golang.org/x/crypto https://github.com/golang/crypto --vcs git
glide mirror set https://golang.org/x/net https://github.com/golang/net --vcs git
glide mirror set https://golang.org/x/tools https://github.com/golang/tools --vcs git
glide mirror set https://golang.org/x/text https://github.com/golang/text --vcs git
glide mirror set https://golang.org/x/image https://github.com/golang/image --vcs git
glide mirror set https://golang.org/x/sys https://github.com/golang/sys --vcs git