From a920b16d3a7164a07e2a8df1d6a9f09319a2c991 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Josef=20P=C3=B6tzl?= Date: Mon, 30 Nov 2026 00:21:43 +0100 Subject: [PATCH] Add workflow to fast-forward dev after merge to main --- .github/workflows/sync-dev-with-main.yml | 25 ++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .github/workflows/sync-dev-with-main.yml diff --git a/.github/workflows/sync-dev-with-main.yml b/.github/workflows/sync-dev-with-main.yml new file mode 100644 index 0000000..8c80dc4 --- /dev/null +++ b/.github/workflows/sync-dev-with-main.yml @@ -0,0 +1,25 @@ +name: Sync dev with main + +on: + pull_request: + types: [closed] + branches: [main] + +permissions: + contents: write + +jobs: + fast-forward-dev: + if: github.event.pull_request.merged == true && github.event.pull_request.head.ref == 'dev' + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v7 + with: + ref: dev + fetch-depth: 0 + + - name: Fast-forward dev to main + run: | + git fetch origin main + git merge --ff-only origin/main + git push origin dev