Smartgit commit amend6/4/2023 ![]() ![]() If this were not the case, then two people pushing to the same repository at about the same time would not know that there was a new commit coming in at the same time and whoever pushed last would lose the work of the previous pusher without either of them realising this. Git refuses to update the remote branch with your branch, because your branch's head commit is not a direct descendent of the current head commit of the branch that you are pushing to. Their later merges will not see the conflicts between old and new that resulted from your amending, so they do not have to suffer. Then people who were unfortunate enough to have based their work on the commit you obliterated by amending and forcing a push will see the resulting merge will see that you favor new over old.
0 Comments
Leave a Reply. |