From 9bc325a1b75fa66dbcc5698fb49a1b4c967cf37f Mon Sep 17 00:00:00 2001 From: Peter Nied Date: Wed, 28 Aug 2024 13:51:59 +0000 Subject: [PATCH] Allow maintainers to opt-out of perf workflow approval requests Tweak the logic for the maintainer list that becomes the assigned approvers on GitHub issues so that maintainers can opt out of this approval process. Signed-off-by: Peter Nied --- .github/workflows/benchmark-pull-request.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/benchmark-pull-request.yml b/.github/workflows/benchmark-pull-request.yml index c494df6e27ce3..b975e8b08b15d 100644 --- a/.github/workflows/benchmark-pull-request.yml +++ b/.github/workflows/benchmark-pull-request.yml @@ -121,7 +121,14 @@ jobs: affiliation: 'all', per_page: 100 }); - return maintainersResponse.data.map(item => item.login).join(', '); + // Any maintainers that do not want to be included on these requests + const excludedMaintainers = [ + 'peternied', + ]; + return maintainersResponse.data + .map(item => item.login) + .filter(approvers => !excludedMaintainers.includes(approvers)) + .join(', '); - uses: trstringer/manual-approval@v1 if: (!contains(steps.get_approvers.outputs.result, github.event.comment.user.login)) with: