From 27a13bf3822c1eab6b75674cd5a83b69aecdf3bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jiri=20Dan=C4=9Bk?= Date: Sun, 10 Aug 2025 18:59:16 +0200 Subject: [PATCH] NO-JIRA: chore(gha): add workflow to label PRs with "review-requested" on creation This can then be tied up with the Slack notification mechanism, so that we aren't spammed by konflux-nudge PRs. Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> --- .../workflows/notify-team-to-review-pr.yml | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .github/workflows/notify-team-to-review-pr.yml diff --git a/.github/workflows/notify-team-to-review-pr.yml b/.github/workflows/notify-team-to-review-pr.yml new file mode 100644 index 0000000000..8e8a5137c1 --- /dev/null +++ b/.github/workflows/notify-team-to-review-pr.yml @@ -0,0 +1,25 @@ +--- +name: Add Review Requested Label +on: # yamllint disable-line rule:truthy + pull_request: + types: [opened] + +permissions: + pull-requests: write + +jobs: + add-label: + if: contains(github.event.pull_request.labels.*.name, 'konflux-nudge') == false + runs-on: ubuntu-latest + steps: + - name: Add review-requested label + uses: actions/github-script@v7 + with: + # language=javascript + script: | + await github.rest.issues.addLabels({ + owner: context.repo.owner, + repo: context.repo.repo, + issue_number: context.payload.pull_request.number, + labels: ['review-requested'] + });