From cb2b357a5e9bd84dd4fb9fb58451927ebb39295f Mon Sep 17 00:00:00 2001 From: Alice Butcher Date: Tue, 4 Apr 2023 10:50:41 +0100 Subject: [PATCH] chore: add action to sync branches when commits are pushed to main --- .github/workflows/sync.yml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .github/workflows/sync.yml diff --git a/.github/workflows/sync.yml b/.github/workflows/sync.yml new file mode 100644 index 0000000..bc66f38 --- /dev/null +++ b/.github/workflows/sync.yml @@ -0,0 +1,27 @@ +name: Sync branches + +on: + push: + branches: + - main + +jobs: + sync-branches: + runs-on: ubuntu-latest + name: "Sync dev and patch branches to latest commit" + steps: + - name: Check out + uses: actions/checkout@v3 + with: + token: ${{ secrets.PERSONAL_ACCESS_TOKEN }} + fetch-depth: 0 + - name: Sync dev branch + uses: connor-baer/action-sync-branch@main + with: + branch: dev + token: ${{ secrets.PERSONAL_ACCESS_TOKEN }} + - name: Sync patch branch + uses: connor-baer/action-sync-branch@main + with: + branch: patch + token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}