[llvm] [Docs][Github] explain how to rectify gh pr merge failure (PR #66223)

Nick Desaulniers via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 13 09:05:28 PDT 2023


================
@@ -131,6 +131,33 @@ You can also merge via the CLI by switching to your branch locally and run:
 
   gh pr merge --squash --delete-branch
 
+If you observe an error message from the above informing you that your pull
+request is not mergeable, then that is likely because upstream has been
+modified since your pull request was authored in a way that now results in a
+merge conflict. You must first resolve this merge conflict in order to merge
+your pull request. In order to do that:
+
+::
+
+  git fetch origin
+  git rebase origin/main
+
+Then fix the source files causing merge conflicts.
+
+::
+
+  git add <files with resolved merge conflicts>
+  <rebuild + retest>
+  git rebase --continue
+
+Finally, you'll need to force push to your branch one more time before you can
+merge:
+
+::
+
+  git push -f
----------------
nickdesaulniers wrote:

done in https://github.com/llvm/llvm-project/pull/66223/commits/b86da6cb1dbdb3932cfa1ec83fe9230831d740b2

https://github.com/llvm/llvm-project/pull/66223


More information about the llvm-commits mailing list