为什么重放现有提交时 git pull --rebase 会失败?
我不明白:当我“git pull --rebase 远程分支”时,它会将我的 HEAD 恢复到其共享根,然后开始重放同时发生的所有远程提交。为什么这些提交有时会失败?它们是干净工作区上的干净提交吗?这不就是rebase的重点吗?
I don't get this: when I 'git pull --rebase remote branch' it reverts my HEAD back to their shared root and then starts replaying all of the remote commits that have happened in the meantime. Why do these commits sometimes fail? They are clean commits on a clean workspace? Isn't that almost the point of rebasing?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您确定这不是您的提交失败吗?
假设您正在一个分支上工作并对特定文件进行大量更改。
现在你想将你的提交重新定位到遥控器的头部。
您的所有更改都将被删除,然后应用所有更改,然后在此基础上重新应用您的所有更改。那么如果他们删除了您正在处理的文件怎么办?或者进行了其他更改,导致您的更改无法应用?
Are you sure it isn't your commits failing?
Suppose you are working on a branch and make a bunch of changes to a specific file.
Now you want to rebase your commits on to whatever the head of the remote is.
All of your changes are removed, then all of theirs are applied, then all of your changes are re-applied on top of that. So what if they deleted the file you're working on? Or otherwise made changes that make your changes impossible to apply?