From dc1cf95471a5a7001f337a65e175c80421eef4a6 Mon Sep 17 00:00:00 2001 From: Emanuele Aina <emanuele.aina@collabora.com> Date: Sun, 14 Mar 2021 00:06:14 +0100 Subject: [PATCH] pkg-merge-upstream-to-downstreams: Always create MR, even with conflicts Create a MR even when the local attempt to merge failed. In that case let the proposed updates branch point to the upstream branch and create a MR to submit it to the downstream branch. This makes the failed updates more visbile and easier to track than the failed pipelines. Signed-off-by: Emanuele Aina <emanuele.aina@collabora.com> --- .../overlay/usr/bin/apertis-pkg-merge-upstream-to-downstreams | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/package-source-builder/overlay/usr/bin/apertis-pkg-merge-upstream-to-downstreams b/package-source-builder/overlay/usr/bin/apertis-pkg-merge-upstream-to-downstreams index 862c5e1..8168cf4 100755 --- a/package-source-builder/overlay/usr/bin/apertis-pkg-merge-upstream-to-downstreams +++ b/package-source-builder/overlay/usr/bin/apertis-pkg-merge-upstream-to-downstreams @@ -109,6 +109,10 @@ def main(): push_this_merge_request() continue + print(f"Submit {proposed_branch} for merging into {downstream_branch} the updates from {upstream_branch}") + git("branch", proposed_branch, upstream_branch) + push_this_merge_request() + print(f"Attempt merging {upstream_branch} into {downstream_branch} via {proposed_branch}") git("checkout", "--force", "-B", "tmp", downstream_branch) apertis_pkg_merge_updates(f"--downstream={downstream_branch}", f"--upstream={upstream_branch}", f"--local-version-suffix={local_suffix}", _fg=True) -- GitLab