From 0d97f088958499424a30e23ce45bd5209c6ba939 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jianxiang=20Wang=20=28=E7=8E=8B=E5=81=A5=E7=BF=94=29?= Date: Tue, 20 Jun 2023 06:26:00 +0800 Subject: [PATCH] Automatically request review regardless of reviewers' collaborator status (#66072) * Replace non-functional code owner file with auto-request-review action * Add an entry for myself to test it * Add @GuardianDll to reviewers.yml * Use modified version of auto-request-review * Only keep the last instance of the request review action running --- .github/CODEOWNERS | 27 --------------- .github/reviewers.yml | 52 ++++++++++++++++++++++++++++ .github/workflows/request-review.yml | 26 ++++++++++++++ 3 files changed, 78 insertions(+), 27 deletions(-) delete mode 100644 .github/CODEOWNERS create mode 100644 .github/reviewers.yml create mode 100644 .github/workflows/request-review.yml diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS deleted file mode 100644 index e9cf6d3fb7b21..0000000000000 --- a/.github/CODEOWNERS +++ /dev/null @@ -1,27 +0,0 @@ -#Note that despite github calling these "owners", a better term would be "alerts" -#Everything in the cataclysm repository remains under a creative commons license, nobody owns the mods. -#In fact, the code "owners" designation is meant to encourage third party -#individuals to contribute to the mod, with the curators notified for reviews. - -/data/mods/Aftershock/ @Maleclypse @John-Candlebury -/data/mods/DinoMod/ @LyleSY -/data/mods/BombasticPerks/ @bombasticSlacks -/data/mods/MMA/ @Hymore246 -/data/mods/classic_zombies/ @I-am-Erk -/data/mods/generic_guns/ @tenmillimaster -/data/mods/Magiclysm/ @KorGgenT -/data/mods/My_Sweet_Cataclysm/ @Fris0uman -/data/mods/ruralbiome/ @I-am-Erk -/data/mods/speedydex/ @KorGgenT -/data/mods/stats_through_kills/ @KorGgenT -/data/mods/Xedra_Evolved/ @Maleclypse -/data/mods/innawood/ @Light-Wave -/data/mods/MA/ @ZhilkinSerg -/data/mods/No_Hope/ @Night-Pryanik - -.clang-tidy @jbytheway -magic*.cpp @KorGgenT -magic*.h @KorGgenT -/tools/ @jbytheway @int-ua -widget.cpp @wapcaplet @dseguin -widget.h @wapcaplet @dseguin diff --git a/.github/reviewers.yml b/.github/reviewers.yml new file mode 100644 index 0000000000000..be27b7037d6d0 --- /dev/null +++ b/.github/reviewers.yml @@ -0,0 +1,52 @@ +files: + 'data/mods/Aftershock/**': + - Maleclypse + - John-Candlebury + 'data/mods/DinoMod/**': + - LyleSY + 'data/mods/BombasticPerks/**': + - bombasticSlacks + 'data/mods/MMA/**': + - Hymore246 + 'data/mods/classic_zombies/**': + - I-am-Erk + 'data/mods/generic_guns/**': + - tenmillimaster + 'data/mods/Magiclysm/**': + - KorGgenT + - GuardianDll + 'data/mods/My_Sweet_Cataclysm/**': + - Fris0uman + 'data/mods/ruralbiome/**': + - I-am-Erk + 'data/mods/speedydex/**': + - KorGgenT + 'data/mods/stats_through_kills/**': + - KorGgenT + 'data/mods/Xedra_Evolved/**': + - Maleclypse + - GuardianDll + 'data/mods/innawood/**': + - Light-Wave + 'data/mods/MA/**': + - ZhilkinSerg + 'data/mods/No_Hope/**': + - Night-Pryanik + + '**/.clang-tidy': + - jbytheway + '**/magic*.cpp': + - KorGgenT + '**/magic*.h': + - KorGgenT + 'tools/**': + - jbytheway + - int-ua + 'src/widget.cpp': + - wapcaplet + - dseguin + 'src/widget.h': + - wapcaplet + - dseguin + 'src/ui_manager.*': + - Qrox diff --git a/.github/workflows/request-review.yml b/.github/workflows/request-review.yml new file mode 100644 index 0000000000000..82fd3c55aaf63 --- /dev/null +++ b/.github/workflows/request-review.yml @@ -0,0 +1,26 @@ +name: Auto request review + + +on: + pull_request_target: + types: [opened, synchronize, ready_for_review, reopened] + + +concurrency: + group: request-review-${{ github.event.pull_request.number }} + cancel-in-progress: true + + +jobs: + auto-request-review: + # Do not spam reviewer with PRs in forks. If fork owners wish to alert + # people of their changes they may change this line themselves. + if: github.repository == 'CleverRaven/Cataclysm-DDA' + name: Auto request review + runs-on: ubuntu-latest + steps: + - name: Request review + uses: qrox/auto-request-review@481e6cd2f5d57b6e914d81ca731211384a76798f + with: + token: ${{ secrets.GITHUB_TOKEN }} + config: .github/reviewers.yml