【Git】git pull fatal: refusing to merge unrelated histories

本地项目add到远程仓库后

git remote add origin https://gitee.com/xxx/git-test.git[仓库地址]

通过 git pull 拉取远程仓库 显示 fatal: refusing to merge unrelated histories

  1. git fetch 没问题
  2. git merge 显示:fatal: refusing to merge unrelated histories

解决方式:
git merge --allow-unrelated-histories

相关推荐

最近更新

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

    2024-03-18 00:24:03       94 阅读
  2. Could not load dynamic library ‘cudart64_100.dll‘

    2024-03-18 00:24:03       100 阅读
  3. 在Django里面运行非项目文件

    2024-03-18 00:24:03       82 阅读
  4. Python语言-面向对象

    2024-03-18 00:24:03       91 阅读

热门阅读

  1. 【Vue2】v-model

    2024-03-18 00:24:03       43 阅读
  2. Git使用

    Git使用

    2024-03-18 00:24:03      33 阅读
  3. 2024年3月职业健康安全管理体系基础考试真题

    2024-03-18 00:24:03       43 阅读
  4. 智能车摄像头灰度处理高效算法(下)

    2024-03-18 00:24:03       45 阅读
  5. ThreadLocal-案例编码实战

    2024-03-18 00:24:03       40 阅读
  6. 17个工作必备的Python自动化代码分享(上篇)

    2024-03-18 00:24:03       34 阅读
  7. clickhouse sql语句

    2024-03-18 00:24:03       37 阅读
  8. Leetcode64. 最小路径和

    2024-03-18 00:24:03       42 阅读
  9. 【MATLAB函数】三点法定位+权重

    2024-03-18 00:24:03       42 阅读
  10. 【Linux】在 Linux 上安装 Zig 编译环境

    2024-03-18 00:24:03       46 阅读