From 661c67a32e024a6ef3167980d8b0a727e6a5c868 Mon Sep 17 00:00:00 2001 From: Leo Fang Date: Sat, 4 Jan 2025 04:48:04 +0000 Subject: [PATCH] add a backport workflow --- .github/workflows/backport.yml | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 .github/workflows/backport.yml diff --git a/.github/workflows/backport.yml b/.github/workflows/backport.yml new file mode 100644 index 00000000..28bb2b41 --- /dev/null +++ b/.github/workflows/backport.yml @@ -0,0 +1,29 @@ +name: Backport merged pull request + +on: + pull_request_target: + types: [closed, labeled] + branches: + - main + +permissions: + contents: write # so it can comment + pull-requests: write # so it can create pull requests + +jobs: + backport: + name: Backport pull request + if: ${{ github.repository_owner == 'nvidia' && + github.event.pull_request.merged == true + }} + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Create backport pull requests + uses: korthout/backport-action@v3 + with: + copy_assignees: true + copy_labels_pattern: true + copy_requested_reviewers: true + label_pattern: to-be-backported + target_branches: 11.8.x