How to revert a merge commit that's already pushed to remote branch?

后端 未结 17 1906
无人及你
无人及你 2020-11-22 07:04

git revert alone won\'t work. -m must be specified, and I\'m pretty confused about it.

Anyone experienced this before?<

17条回答
  •  野趣味
    野趣味 (楼主)
    2020-11-22 07:58

    -m1 is the last parent of the current branch that is being fixed, -m 2 is the original parent of the branch that got merged into this.

    Tortoise Git can also help here if command line is confusing.

提交回复
热议问题