From 7b9342a63aeb532db6d68e87a587161874e72e0a Mon Sep 17 00:00:00 2001 From: Martin McKeaveney Date: Thu, 6 Jul 2023 14:28:50 +0100 Subject: [PATCH 1/3] add stale workflow job --- .github/stale.yml | 19 ------------------- .github/workflows/stale_bot.yml | 29 +++++++++++++++++++++++++++++ 2 files changed, 29 insertions(+), 19 deletions(-) delete mode 100644 .github/stale.yml create mode 100644 .github/workflows/stale_bot.yml diff --git a/.github/stale.yml b/.github/stale.yml deleted file mode 100644 index 2a2c10cb7d..0000000000 --- a/.github/stale.yml +++ /dev/null @@ -1,19 +0,0 @@ -# Configuration for probot-stale - https://github.com/probot/stale -# Number of days of inactivity before an Issue or Pull Request becomes stale -daysUntilStale: 60 -# Number of days of inactivity before an Issue or Pull Request with the stale label is closed. -# Set to false to disable. If disabled, issues still need to be closed manually, but will remain marked as stale. -daysUntilClose: false -# Issues with these labels will never be considered stale -exemptLabels: - - pinned - - security - - roadmap -# Label to use when marking an issue as stale -staleLabel: stale -# Comment to post when marking an issue as stale. Set to `false` to disable -markComment: > - This issue has been automatically marked as stale because it has not had - recent activity. -# Comment to post when closing a stale issue. Set to `false` to disable -closeComment: false diff --git a/.github/workflows/stale_bot.yml b/.github/workflows/stale_bot.yml new file mode 100644 index 0000000000..6bf3e3343b --- /dev/null +++ b/.github/workflows/stale_bot.yml @@ -0,0 +1,29 @@ +name: Close stale issues and PRs # https://github.com/actions/stale +on: + workflow_dispatch: + schedule: + - cron: '30 1 * * *' # 1:30 every morning + +jobs: + stale: + runs-on: ubuntu-latest + steps: + - uses: actions/stale@v8 + with: + # stale rules + days-before-stale: 60 + days-before-pr-stale: 30 + stale-issue-label: stale + stale-issue-message: "This issue has been automatically marked as stale because it has not had any activity for 60 days." + + # close rules + # days after being marked as stale to close + days-before-close: 30 + close-issue-label: closed-stale + close-issue-message: This issue has been automatically closed it has not had recent activity." + days-before-pr-close: 7 + + # exemptions + exempt-pr-labels: pinned,security,roadmap + + From 5e7868ecb7987735f75ccdb680d864161f17e5cc Mon Sep 17 00:00:00 2001 From: Martin McKeaveney Date: Thu, 6 Jul 2023 14:32:11 +0100 Subject: [PATCH 2/3] update the stale timing on PRs --- .github/workflows/stale_bot.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/stale_bot.yml b/.github/workflows/stale_bot.yml index 6bf3e3343b..a5595394a7 100644 --- a/.github/workflows/stale_bot.yml +++ b/.github/workflows/stale_bot.yml @@ -12,7 +12,7 @@ jobs: with: # stale rules days-before-stale: 60 - days-before-pr-stale: 30 + days-before-pr-stale: 7 stale-issue-label: stale stale-issue-message: "This issue has been automatically marked as stale because it has not had any activity for 60 days." From 079f0eab2a5c2a50856123979bce6b7eb24cc945 Mon Sep 17 00:00:00 2001 From: Martin McKeaveney Date: Thu, 6 Jul 2023 14:32:47 +0100 Subject: [PATCH 3/3] update closed issue message --- .github/workflows/stale_bot.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/stale_bot.yml b/.github/workflows/stale_bot.yml index a5595394a7..8cda3a9342 100644 --- a/.github/workflows/stale_bot.yml +++ b/.github/workflows/stale_bot.yml @@ -20,7 +20,7 @@ jobs: # days after being marked as stale to close days-before-close: 30 close-issue-label: closed-stale - close-issue-message: This issue has been automatically closed it has not had recent activity." + close-issue-message: This issue has been automatically closed it has not had any activity in 90 days." days-before-pr-close: 7 # exemptions