I wound up creating a GitHub action, and I hope this helps someone else. I read a bunch of suggestions and came up with the following generic .github/workflows/automerge-appflow.yml
which is scheduled, but can also be triggered manually:
name: Merge to Appflow
# Auto-merge the appflow branch with the main branch
permissions:
contents: write # Needed for the final "git push" to work
on:
workflow_dispatch:
schedule:
# 6pm EST Monday to Friday (11PM UTC days 1-5 of the week)
- cron: '0 23 * * 1-5'
env:
MY_BRANCH: appflow
MAIN_BRANCH: main
jobs:
merge:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: ${{env.MY_BRANCH}}
- name: Merge
run: |
git config user.name "Automerge Bot"
git config user.email "gitbot@{mydomain.com}"
git config pull.rebase false
git pull origin ${{env.MAIN_BRANCH}}
- name: Push
run: git push