From 703127071857d40747e28270af123508bf3bf195 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20M=C3=BCller?= Date: Tue, 26 Dec 2023 15:03:04 -0800 Subject: [PATCH] Add GitHub workflow to close stale PRs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This change introduces a GitHub workflow that takes care of automatically closing stale pull requests after a sufficiently long time has elapsed without any action. Signed-off-by: Daniel Müller --- .github/workflows/stale.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 .github/workflows/stale.yml diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml new file mode 100644 index 00000000..e328c20e --- /dev/null +++ b/.github/workflows/stale.yml @@ -0,0 +1,19 @@ +name: Close stale PRs +on: + schedule: + - cron: '30 1 * * *' + +jobs: + stale: + runs-on: ubuntu-latest + steps: + - uses: actions/stale@v9 + with: + # Disable staleness logic for issues. + days-before-stale: -1 + days-before-close: -1 + # Explicitly enable staleness logic for pull requests. + days-before-pr-stale: 30 + days-before-pr-close: 5 + stale-pr-message: 'This pull request is considered stale because it has been open 30 days with no activity. Remove stale label or comment or it will be closed in 5 days.' + close-pr-message: 'Closing pull request as it is stale.'