问题描述
今天通过git地址在本地拉取代码时,拉取的很慢,拉到百分之九十八或者九十九的时候就会拉取失败,像我下面拉到百分之百,也没拉下来,
历经层层磨难终于找到了解决方案,下面分享给大家,希望可以解决你们的问题
报错信息
git clone https://xxxx.xxxx.cn/a/xxxx/glxt_applent Cloning into 'glxt_applent'... remote: Counting objects: 2219, done remote: Finding sources: 100% (37625/37625) error: RPC failed; curl 18 transfer closed with outstanding read data remaining fetch-pack: unexpected disconnect while reading sideband packet fatal: early EOF fatal: fetch-pack: invalid index-pack output
解决方案
在git地址后面加上--depth=1
我的问题就是通过这种方式解决的,大家也可以试一下
参考示例
git clone https:/