问题描述:
~/OK62xx-linux-sdk/OK62xx-linux-kernel$ git push origin master
Counting objects: 83919, done.
Delta compression using up to 144 threads.
Compressing objects: 100% (75697/75697), done.
Writing objects: 100% (83919/83919), 232.41 MiB | 15.79 MiB/s, done.
Total 83919 (delta 7471), reused 83749 (delta 7357)
remote: Resolving deltas: 100% (7471/7471), done.
To /home/machao/sdk9.0/OK62xx-linux-kernel.git/
! [remote rejected] master -> master (shallow update not allowed)
1.尝试使用git fetch --unshallow origin
, git fetch --update-shallow
修复,但是没有效果
2.使用git push --mirror
, 也不成功
3.配置添加shallowUpdate
也不成功, git config --local --add receive.shallowUpdate true
:
4.最后使用git filter-branch -- --all
,去掉克隆的提交的 grafted 标记,操作成功。