赞
踩
示例私有地址:
gitee.com/takujo_admin 或者igitlab.com
多个私有地址,分割,示例:
gitee.com,igitlab.com
go env -w GOPRIVATE="私有地址"
go env -w GONOPROXY="私有地址"
go env -w GONOSUMDB="私有地址"
即刻生效
git config --global url."替换后地址".insteadof "原仓库地址"
实际就是链接的字符串内容替换
示例:
把https方式替换为ssh方式
git config --global url."git@gitee.com:takujo_admin".insteadof "https://gitee.com/takujo_admin"
把https方式替换为http方式
git config --global url."http://gitee.com/takujo_admin".insteadof "https://gitee.com/takujo_admin"
如果还失败,补充环境变量
go env -w GOINSECURE="私有地址"
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。