Repo sync 时出现fatal_ couldn‘t find remote ref refs_heads_master问题解决

在这里插入图片描述

repo sync默认的origin分支是master,它默认会依赖master,但是我们的manifests分支是main,需要解决这个问题主要执行下面的几步:

  1. 更新repo到最新版本
cd .repo/repo 
git pull # 更新repo
  1. 前往git库创建origin master

image.png

  1. 在manifests下拉代码,把origin master拉下来
cd .repo/manifests
git pull 
  1. 执行repo sync
cd .repo/manifests 
git checkout <test_branch> 
repo sync

此时就不会报题中的错误了,记得origin master可以删掉。

最近更新

  1. docker php8.1+nginx base 镜像 dockerfile 配置

    2023-12-17 09:12:02       94 阅读
  2. Could not load dynamic library ‘cudart64_100.dll‘

    2023-12-17 09:12:02       100 阅读
  3. 在Django里面运行非项目文件

    2023-12-17 09:12:02       82 阅读
  4. Python语言-面向对象

    2023-12-17 09:12:02       91 阅读

热门阅读

  1. LeetCode经典150题Golang版.189. 轮转数组

    2023-12-17 09:12:02       67 阅读
  2. 关于vue3中响应式依赖注入provide/inject

    2023-12-17 09:12:02       59 阅读
  3. Docker可视化管理工具docker.ui的搭建

    2023-12-17 09:12:02       68 阅读
  4. RecyclerView中的设计模式解读

    2023-12-17 09:12:02       64 阅读
  5. linux修复SSL/TLS协议信息泄露漏洞(CVE-2016-2183)

    2023-12-17 09:12:02       66 阅读
  6. 串口通信(5)-C#串口通信数据接收不完整解决方案

    2023-12-17 09:12:02       60 阅读
  7. Kubernetes Pod 网段与主机内网网段互通

    2023-12-17 09:12:02       66 阅读
  8. 基于SpringBoot和微信小程序的校园快递平台系统

    2023-12-17 09:12:02       63 阅读