Undoing a 'git push'

前端 未结 12 986
遥遥无期
遥遥无期 2020-11-22 13:45

Here\'s what I did on my supposed-to-be-stable branch...

% git rebase master
First, rewinding head to repla         


        
12条回答
  •  渐次进展
    2020-11-22 14:11

    you can use the command reset

    git reset --soft HEAD^1
    

    then:

    git reset 
    git commit --amend
    

    and

    git push -f
    

提交回复
热议问题