【工具使用系列】关于 加速 git clone,你需要知道的事

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/MosesAaron/article/details/81414461

如何加速 git clone

使用 http 代理的方式

  1. 从代理客户端或者命令行,获取 http 代理地址

    https 代理信息页面.截图
  2. 往.gitconfig, 添加 http 代理地址
    通过命令行工具,键入git config 命令设置 https 代理,

    git config命令行.截图

    git config --global http.proxy https://127.0.0.1:61293

    或者通过文本工具, 添加 https 代理地址到文件 .gitconfig (C:\Users\Your Name\.gitconfig)


    .gitconfig编辑文本.截图

    [http]
        proxy = 127.0.0.1:61293
  3. 测试一下,比较添加前与添加后的效果
    使用 git clone 获取 monodevelop

git clone https://github.com/mono/monodevelop --recursive


使用 http 代理前后效果对比.截图
(左侧为添加前的效果,右侧为添加后的效果)
*使用 http 代理后,git clone 提速效果很明显~

猜你喜欢

转载自blog.csdn.net/MosesAaron/article/details/81414461