diff --git a/ci/README.md b/ci/README.md index 52a8925cc..6e221b351 100644 --- a/ci/README.md +++ b/ci/README.md @@ -156,9 +156,9 @@ git merge "community/$PR_BRANCH" familiar with the change. 5. You should rerun the `check-merge-to-enterprise` check on `community/$PR_BRANCH`. You can use re-run from failed option in circle CI. -6. You can now merge the PR on community. Be sure to NOT use "squash and merge", +6. You can now merge the PR on enterprise. Be sure to NOT use "squash and merge", but instead use the regular "merge commit" mode. -7. You can now merge the PR on enterprise. Be sure to NOT use "squash and merge", +7. You can now merge the PR on community. Be sure to NOT use "squash and merge", but instead use the regular "merge commit" mode. The subsequent PRs on community will be able to pass the diff --git a/ci/check_enterprise_merge.sh b/ci/check_enterprise_merge.sh index 097e1aed5..040a5c224 100755 --- a/ci/check_enterprise_merge.sh +++ b/ci/check_enterprise_merge.sh @@ -65,6 +65,14 @@ fi # undo partial merge git merge --abort +# If we have a conflict on enterprise merge on the master branch, we have a problem. +# Provide an error message to indicate that enterprise merge is needed. +if [[ $PR_BRANCH = master ]]; then + echo "ERROR: Master branch has merge conlicts with enterprise-master." + echo "Try re-running this job if you merged community PR before enterprise PR. Otherwise conflicts need to be resolved as a separate PR on enterprise." + exit 1 +fi + if ! git fetch enterprise "$PR_BRANCH" ; then echo "ERROR: enterprise/$PR_BRANCH was not found and community PR branch could not be merged into enterprise-master" exit 1