[git] If you have pushed to the remote branch and find a small problem that needs to be modified, is there a way to achieve the effect of git commit --amend?
PHP中文网
PHP中文网 2017-05-02 09:44:20
0
1
735

When you have pushed to the remote branch, if you execute git commit --amend and then execute git push, an error will be reported, requiring you to execute git pull first. However, after executing git pull, it seems to become merge and cannot be used anymore. Invisible modification. I would like to ask you how to achieve the same effect in this situation.

PHP中文网
PHP中文网

认证高级PHP讲师

reply all(1)
刘奇

No way. There is no way to take back the water that is thrown out, the words that are spoken, and the submission that is pushed out.

But if you are sure that only you can access your remote warehouse, you can overwrite it with git push -f. If there are multiple people, they may have fetched that commit, and you have to find them and "silence" them.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template