From 8c8b2f4a4d9e7630e9bca3e8e576828d9de33d55 Mon Sep 17 00:00:00 2001 From: Raghavendra Talur Date: Fri, 22 Nov 2024 16:07:00 -0500 Subject: [PATCH] github: automatically label the PRs with matching branches Signed-off-by: Raghavendra Talur --- .github/labeler.yml | 17 +++++++++++++++++ .github/workflows/labeler.yml | 16 ++++++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 .github/labeler.yml create mode 100644 .github/workflows/labeler.yml diff --git a/.github/labeler.yml b/.github/labeler.yml new file mode 100644 index 000000000..a0ad214c5 --- /dev/null +++ b/.github/labeler.yml @@ -0,0 +1,17 @@ +# SPDX-FileCopyrightText: The RamenDR authors +# SPDX-License-Identifier: Apache-2.0 + +--- +# Add branch labels to the PRs matching their branch names +branch/main: + - base-branch: 'main' +branch/release-4.14: + - base-branch: 'release-4.14' +branch/release-4.15: + - base-branch: 'release-4.15' +branch/release-4.16: + - base-branch: 'release-4.16' +branch/release-4.17: + - base-branch: 'release-4.17' +branch/release-4.18: + - base-branch: 'release-4.18' diff --git a/.github/workflows/labeler.yml b/.github/workflows/labeler.yml new file mode 100644 index 000000000..81e4bfcd6 --- /dev/null +++ b/.github/workflows/labeler.yml @@ -0,0 +1,16 @@ +# SPDX-FileCopyrightText: The RamenDR authors +# SPDX-License-Identifier: Apache-2.0 + +--- +name: label pr +on: # yamllint disable-line rule:truthy +- pull_request_target + +jobs: + labeler: + permissions: + contents: read + pull-requests: write + runs-on: ubuntu-latest + steps: + - uses: actions/labeler@v5