From 81f48ff65c390bbaaa8602a8a4eec2a740a65a7b Mon Sep 17 00:00:00 2001 From: Brian Dukes Date: Fri, 12 Nov 2021 14:52:09 -0600 Subject: [PATCH] Add workflow to auto-open PRs to v9.11 branch --- .../open-merged-pr-to-future-9.11.0.yml | 32 +++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 .github/workflows/open-merged-pr-to-future-9.11.0.yml diff --git a/.github/workflows/open-merged-pr-to-future-9.11.0.yml b/.github/workflows/open-merged-pr-to-future-9.11.0.yml new file mode 100644 index 00000000000..1a9a2582c03 --- /dev/null +++ b/.github/workflows/open-merged-pr-to-future-9.11.0.yml @@ -0,0 +1,32 @@ +name: Open Merged PR to release/9.11.0 Branch + +on: + pull_request: + types: [closed] + branches: + - develop + +jobs: + open-merged-pr-to-ten-branch: + runs-on: ubuntu-latest + if: ${{ github.event.pull_request.merged }} + steps: + - uses: actions/checkout@v2.3.4 + + - uses: peterjgrainger/action-create-branch@v2.0.1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + branch: v9.11.0/${{ github.event.pull_request.head.ref }}-${{ github.event.pull_request.head.merge_commit_sha }} + + - name: Create Pull Request + uses: repo-sync/pull-request@v2.6 + with: + source_branch: v9.11.0/${{ github.event.pull_request.head.ref }}-${{ github.event.pull_request.head.merge_commit_sha }} + destination_branch: release/9.11.0 + pr_title: v9.11.0 ${{ github.event.pull_request.title }} + pr_body: | + Applying #${{ github.event.pull_request.number }} to release/9.11.0 + ${{ github.event.pull_request.body }} + pr_label: ${{ join(github.event.pull_request.labels.*.name) }} + github_token: ${{ secrets.GITHUB_TOKEN }}