Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

我通过下面的命令合并PR

git checkout -b malienist-pr/mxeditor-types master
git pull https://github.com/malienist/mxgraph-type-definitions.git pr/mxeditor-types

中间手动进行了一下rebase,合并了提交信息,然后

git checkout master
git merge --no-ff malienist-pr/mxeditor-types

这个时候别人的提交已经合并到master了,但是PR的状态还是打开的,并且会有冲突,因为我进行了rebase。

这种情况应该怎么办呢?我现在直接关掉了PR,但是感觉这样不太好。

https://github.com/hungtcs/mx...


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
2.4k views
Welcome To Ask or Share your Answers For Others

1 Answer

  1. 切换到 master/main 版本
  2. git reset --mixed 版本号 恢复到合并之前的版本
  3. git push -f 强制替换线上版本
  4. 在线上合并
  5. git pull 拉下来最新版本

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...