diff --git a/Git/get私库项目.md b/Git/get私库项目.md new file mode 100644 index 0000000..a6fd83d --- /dev/null +++ b/Git/get私库项目.md @@ -0,0 +1,17 @@ +go get只支持https,若只有http或ssh,需要配置 + +#### ssh +```bash +# ssh +# 在.gitconfig文件中替换 +[url "ssh://git.xxx.com:2222"] + insteadOf https://git.xxx.com/ +``` +#### http +```bash +go env -w GOINSECURE=git.xxx.com +``` +#### 配置私库 +```bash +go env -w GOPRIVATE=git.xhupo.com +```