使用git pull拉取代码的时候,无法拉取最新代码,报"unable to update local ref"错误。

除了重新clone一份代码外,还可以使用如下解决方案:

1、切换到之前clone代码目录下,执行命令git gc --prune=now

2、再执行命令git remote prune origin

3、再次使用git pull

git pull报“unable to update local ref”解决方案的更多相关文章

  1. 使用git pull拉取代码的时候,无法拉取最新代码,报"unable to update local ref"错误。

    使用git pull拉取代码的时候,无法拉取最新代码,报"unable to update local ref"错误. 除了重新clone一份代码外,还可以使用如下解决方案: .切 ...

  2. git pull fails “unable to resolve reference” “unable to update local ref”

    问题 由于有人rebase了分支,或者不知道怎么搞的.其他人拉取代码的时候,发现拉不下来. >git fetch error: cannot lock ref 'refs/remotes/ori ...

  3. git pull时 git cannot lock ref XXXXXX (unable to update local ref)错误解决方案

    git pull :  git cannot lock ref    XXXXXX (unable to update local ref) pull代码的时候出现的错误,导致代码拉不下来. 看了一下 ...

  4. git (unable to update local ref )

    https://stackoverflow.com/questions/2998832/git-pull-fails-unable-to-resolve-reference-unable-to-upd ...

  5. Eclipse git pull 报Nothing to fetch 异常原因

    eclipse git pull 报错 // 使用这个配置就可以正常pull了        [core]        symlinks = false         repositoryform ...

  6. git pull报错,error: cannot lock ref导致拉流失败

    使用git命令删除相应refs文件,git update-ref -d refs/remotes/XXX,或者手动删除文件 简单粗暴强行git pull,执行git pull -p 原文:https: ...

  7. git pull报错:There is no tracking information for the current branch

    报错: There is no tracking information for the current branch. Please specify which branch you want to ...

  8. git pull 报错 You have not concluded your merge (MERGE_HEAD exists).

    git pull时报错 解决方案:

  9. VSTS 执行git pull报错问题修复

    VSTS中进行双向同步配置的git pull指令如下: 运行时报错,Log如下图所示: 原因说的很清楚了,需要提前执行以下两条git config指令: git config --global use ...

随机推荐

  1. LOJ2541 PKUWC2018 猎人杀 期望、容斥、生成函数、分治

    传送门 首先,每一次有一个猎人死亡之后\(\sum w\)会变化,计算起来很麻烦,所以考虑在某一个猎人死亡之后给其打上标记,仍然计算他的\(w\),只是如果打中了一个打上了标记的人就重新选择.这样对应 ...

  2. 在属性property做一些简单的验证

    开发C#的程序,写到属性property时,我们可以在Set方法中做一些简单的规则验证: 如下面,Insus.NET写一个Age属性,只允许用户输入10以内的数字: class AA { privat ...

  3. c# WPF 设置窗口一直在其中窗口后面/底层窗口

    using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.W ...

  4. 有关素数判断的一些算法(总结&&对比)

    素性测试是数论题中比较常用的一个技巧.它可以很基础,也可以很高级(哲学).这次主要要介绍一下有关素数判断的奇技淫巧 素数的判断主要分为两种:范围筛选型&&单个判断型 我们先从范围筛选型 ...

  5. 机器学习(三)--- scala学习笔记

    Scala是一门多范式的编程语言,一种类似Java的编程语言,设计初衷是实现可伸缩的语言.并集成面向对象编程和函数式编程的各种特性. Spark是UC Berkeley AMP lab所开源的类Had ...

  6. 聊聊Zookeeper应用场景、架构设计、选主机制

    Zookeeper作为一个分布式协调系统提供了一项基本服务:分布式锁服务,分布式锁是分布式协调技术实现的核心内容.像配置管理.任务分发.组服务.分布式消息队列.分布式通知/协调等,这些应用实际上都是基 ...

  7. python 小问题收集

    1,python安装sqlclient yum install python36u python36u-devel yum install gcc mariadb-devel pip3 install ...

  8. Java的JDK下Hashtable与HashMap的区别

    时间角度: Hashtable * @since JDK1.0 ; HashMap* @since   1.2 基类与接口角度: public class Hashtable<K,V> e ...

  9. Appium学习笔记1_获取到APK安装包的Package以及Activity属性值

    我们设置DesiredCapabilities属性值得时候需要设置"appPackage"和"appActivity",如何获取到这两个值呢? 这两个值不是随便 ...

  10. mybatis批量插入和批量更新

    批量插入数据使用的sql语句是: insert into table (aa,bb,cc) values(xx,xx,xx),(oo,oo,oo) mybatis中mapper.xml的代码如下: & ...