git clone加速(实测推荐)

Github的重要性就不需要赘述了,但是github的服务器在国外,国内访问速度是非常慢的,下边介绍几种git clone时加速的方法。

分享一个工作学习都会用到的工具,有很多chatgpt都可以免费用,无需墙无需登录和无限制,浏览器打开 https://hao.94c.cn

第一种:在git仓库前添加gitclone.com的前缀(推荐)

比如,作者想要下载这个库,只需要原始的url

git clone https://github.com/tendermint/tendermint.git

将url改为:

git clone https://gitclone.com/github.com/tendermint/tendermint.git

第二种 设置git参数

git config --global url."https://gitclone.com/".insteadOf https://git clone https://github.com/tendermint/tendermint.git

第三种 使用cgit工具

下载链接:https://github.com/git-cloner/gitcache/releases

cgit clone https://github.com/tendermint/tendermint.git

第四种 使用本地代理

代理可以全局设置,也可以临时设置,具体设置如下:

全局设置:

git config --global --unset http.proxy

git config --global http.proxy 'http://127.0.0.1:port'

临时设置:

git clone -c https.proxy="http://127.0.0.1:port"

转载:https://www.jianshu.com/p/00676becb9d4

评论 16
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值