Skip to content

ci: add back-merge workflow to sync main into development#548

Merged
will-yuponce-db merged 1 commit into
mainfrom
ci/backmerge-main-to-development
Jun 19, 2026
Merged

ci: add back-merge workflow to sync main into development#548
will-yuponce-db merged 1 commit into
mainfrom
ci/backmerge-main-to-development

Conversation

@will-yuponce-db

Copy link
Copy Markdown
Contributor

Summary

Adds .github/workflows/backmerge-main-to-development.yml to keep the development branch in sync with main ("point main back down to development").

Behavior

  • Triggers on every push to main (plus manual workflow_dispatch).
  • Ensures an open PR exists merging main → development.
  • No-op when development already contains main (git merge-base --is-ancestor).
  • Reuses an existing open back-merge PR rather than creating duplicates (a branch-to-branch PR auto-tracks new commits on main).

Why PR-based instead of a direct push/merge

  • Respects branch protection on development.
  • If main and development have diverged, GitHub surfaces the conflicts on the PR for manual resolution instead of force-pushing over them.

Permissions: pull-requests: write only (uses the built-in GITHUB_TOKEN).

If you'd rather it auto-merge clean back-merges (no review), I can add gh pr merge --auto — left out by default so maintainers stay in control.

Adds a workflow that, on every push to main (and via workflow_dispatch),
ensures an open PR exists merging main -> development, keeping the
development branch in sync with main. PR-based rather than a direct push
so it respects branch protection on development and surfaces merge
conflicts for manual resolution. No-ops when development already contains
main, and reuses an existing open back-merge PR instead of creating
duplicates.
@will-yuponce-db will-yuponce-db requested a review from a team as a code owner June 19, 2026 16:29

@larsgeorge-db larsgeorge-db left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@will-yuponce-db will-yuponce-db added this pull request to the merge queue Jun 19, 2026
Merged via the queue into main with commit 037de8c Jun 19, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants