1. 当项目过大时,git clone时会出现error: RPC failed; HTTP curl The requested URL returned error: Gateway Time-out的问题
  2.  
  3. 解决方法很简单,在git clone时加上--depth=1即可解决
  4.  
  5. 克隆的项目只包含最近的一次commit的一个分支,体积很小,即可解决文章开头提到的项目过大导致Timeout的问题,但会产生另外一个问题,他只会把默认分支clone下来,其他远程分支并不在本地,所以这种情况下,需要用如下方法拉取其他分支:
  6.  
  7. $ git clone --depth https://github.com/dogescript/xxxxxxx.git
  8. $ git remote set-branches origin 'remote_branch_name'
  9. $ git fetch --depth origin remote_branch_name
  10. $ git checkout remote_branch_name

git clone时加上--depth 1的更多相关文章

  1. git clone时出现 error:inflate:data stream error(incorrect data check)

    git clone时出现 error:inflate:data stream error(incorrect data check) fatal:serrious inflate inconsiste ...

  2. idea在使用git clone 时出现Filename too long

    idea在使用git clone 时出现Filename too long的报错信息,使用如下命令就可以解决该问题:在 git bash命令模式下,运行命令 git config --global c ...

  3. git clone 时注意点

    环境: 在公司访问外网需要设置代理,另外,在公司局域网内架设了一台 GIT 服务器. 在使用 git clone 时,不能设置成 git 使用代理: git config --global http. ...

  4. Git clone时出现fatal:the remote end hung up unexpectedly

    以HTTPS方式进行git clone时出现如下错误: 方法1:增大缓存 git config http.postBuffer 524288000 尝试无效: 方法2:配置git的最低速度和最低速度时 ...

  5. git clone时RPC failed; curl 18 transfer closed with outstanding read data remaining

    git clone时报RPC failed; curl 18 transfer closed with outstanding read data remaining 错误 原因1:缓存区溢出 解决方 ...

  6. git clone时,报403错误,完美解决方案

    首先命令行操作结果如下: root@zhiren-PowerEdge-T110-II:/zrun# git clone https://git.coding.net/xxxxxxxx/xxxx.git ...

  7. 使用windows 命令行执行Git clone时出现Host key error

    由于是在java中执行cmd命令调用git clone,导致git读取不到用户的ssh key,需要设置环境变量Home为正确的用户路径: cmd /c set HOME=C:/Users/你的用户名 ...

  8. git clone时,提示warning: remote HEAD refers to nonexistent ref, unable to checkout

    一.环境 发行版:Ubuntu 18.04.1 LTS 代号:bionic 内核版本:4.15.0-30-generic 二.背景 git clone https://source.codeauror ...

  9. Git clone时出现Please make sure you have the correct access rights and the repository exists.问题已解决。

    看了好多资料终于搞定了git 中clone命令报错这个问题,废话不多说直接上步骤希望对大家有帮助. 1   删除.ssh文件夹(直接搜索该文件夹)下的known_hosts(手动删除即可,不需要git ...

随机推荐

  1. mnist数据的预测结果以及批量处理

    import sys, os sys.path.append('F:\ml\DL\source-code') from dataset.mnist import load_mnist from PIL ...

  2. TDOA 之 基站逻辑代码实现

    在前一篇博文里描述了基站的逻辑部分,这里贴出来具体代码实现.https://www.cnblogs.com/tuzhuke/p/11689881.html 1 Sync 信息部分 case 'S': ...

  3. HDU 6000 - Wash

    /* HDU 6000 - Wash [ 贪心 ] 题意: L 件衣服,N 个洗衣机,M 个烘干机,给出每个洗衣机洗一件衣服的时间和烘干机烘干一件衣服的时间,问需要的最少时间是多少 分析: 先求出L件 ...

  4. Javascript基础——函数

    一 函数的介绍 1.概念:由一堆代码按照一定的规则,组成实现了某个功能,通过函数自身或事件调用 函数的特点: 忽略细节:只关注其实现的功能,不关注内部构造: 重复使用:函数可以实现代码的重复利用: 选 ...

  5. 51nod 1577 异或凑数 线性基的妙用

    \(OTZgengyf\)..当场被吊打\(QwQ\) 思路:线性基 提交:\(3\)次 错因:往里面加数时\(tmp.p\)与\(i\)区分不清(还是我太菜了) 题解: 我们对每个位置的线性基如此操 ...

  6. 007_硬件基础电路_RC复位电路中二极管的作用

    --------------------- 作者:碎碎思 来源:CSDN 原文:https://blog.csdn.net/Pieces_thinking/article/details/781110 ...

  7. 078_使用 egrep 过滤 MAC 地址

    #!/bin/bash#MAC 地址由 16 进制组成,如 AA:BB:CC:DD:EE:FF#[0-9a-fA-F]{2}表示一段十六进制数值,{5}表示连续出现 5 组前置:的十六进制egrep ...

  8. 四十二.部署MongoDB服务 、 MongoDB基本使用

    1. 部署MongoDB服务  192.168.4.50 创建服务工作目录 ]# mkdir /usr/local/mongodb ]# cd /usr/local/mongodb/ ]# mkdir ...

  9. pytz

    pytz django的模型类中使用的 DateTimeField 字段,自动添加下来的携带有时区信息,2019-06-19T03:58:11.937945Z 在我的逻辑中需要对时间进行比较,我使用了 ...

  10. linux系列(十一):nl命令

    1.命令格式: nl [选项] [文件] 2.命令功能: nl(Number of Lines) 将指定的文件添加行号标注后写到标准输出.如果不指定文件或指定文件为"-" ,程序将 ...