sourcetree刪除錯誤提交

假設你有3個commit以下: commit 3 commit 2 commit 1 其中最後一次提交commit 3是錯誤的,那麼能夠執行: git reset --hard HEAD~1 你會發現,HEAD is now at commit 2。 而後再使用git push --force將本次變動強行推送至服務器。這樣在服務器上的最後一次錯誤提交也完全消失了。 值得注意的是,這類操做比較比較
相關文章
相關標籤/搜索