From 0094464dad9bd4304d30a94aa39f30d94403a013 Mon Sep 17 00:00:00 2001 From: Sophie Schoenmeyer <107952697+sophies927@users.noreply.github.com> Date: Wed, 24 Jul 2024 21:31:58 -0700 Subject: [PATCH 1/2] Create new stale issue workflow Create new stale issue workflow that breaks up existing workflow into 4 separate parts: 1) Apply stale label to issues with no activity for 30 days 2) Remove stale label if someone comments on a stale issue 3) Close issues labeled stale with no activity for an additional 30 days 4) Reopen issue if someone comments on closed stale issue Will temporarily disable existing stale issue workflow before merging this one for testing purposes If this workflow works, I'll remove the old one + corresponding files --- .github/workflows/new_stale_close.yml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 .github/workflows/new_stale_close.yml diff --git a/.github/workflows/new_stale_close.yml b/.github/workflows/new_stale_close.yml new file mode 100644 index 0000000000000..7adcba18957a3 --- /dev/null +++ b/.github/workflows/new_stale_close.yml @@ -0,0 +1,21 @@ +name: Close Stale Issues +description: Close stale issues that have not been updated in 30 days +resource: repository +configuration: + resourceManagementConfiguration: + scheduledSearches: + - frequencies: + - daily: + time: 15:00 + filters: + - hasLabel: + label: stale + - isIssue + - isOpen + - isNotAssigned + - noActivitySince: + days: 30 + actions: + - addReply: + reply: "Closing issue due to no activity in 90 days" + - closeIssue From 5956b7802fb0b1ffc577912e16ce88320fa661c4 Mon Sep 17 00:00:00 2001 From: Sophie Schoenmeyer <107952697+sophies927@users.noreply.github.com> Date: Wed, 24 Jul 2024 22:13:57 -0700 Subject: [PATCH 2/2] Update new_stale.yml to combine adding stale label + closing stale issues --- .github/workflows/new_stale.yml | 60 +++++++++++++++++++++++++++ .github/workflows/new_stale_close.yml | 21 ---------- 2 files changed, 60 insertions(+), 21 deletions(-) create mode 100644 .github/workflows/new_stale.yml delete mode 100644 .github/workflows/new_stale_close.yml diff --git a/.github/workflows/new_stale.yml b/.github/workflows/new_stale.yml new file mode 100644 index 0000000000000..cb794bad171a4 --- /dev/null +++ b/.github/workflows/new_stale.yml @@ -0,0 +1,60 @@ +id: scheduledSearch.updateStaleIssues +name: Update Stale Issues +description: Update stale issues that have not been active in 30 days +resource: repository +configuration: + resourceManagementConfiguration: + scheduledSearches: + - description: >- + Search for Issue where - + * Issue is open + * Issue is not assigned + * Issue has not had activity in the last 30 days + + Then - + * Apply the stale label to Issue + frequencies: + - daily: + time: 15:00 + filters: + - isIssue + - isOpen + - isNotAssigned + - isNotLabeledWith: + label: contributions welcome + - isNotLabeledWith: + label: documentation + - isNotLabeledWith: + label: feature request + - isNotLabeledWith: + label: regression + - noActivitySince: + days: 30 + actions: + - addReply: + reply: "Applying stale label due to no activity in 30 days" + - addLabel: + label: stale + - description: + Search for Issue where - + * Issue is open + * Issue is labeled stale + * Issue has not had activity in the last 30 days + + Then - + * Close the issue + frequencies: + - daily: + time: 15:00 + filters: + - hasLabel: + label: stale + - isIssue + - isOpen + - isNotAssigned + - noActivitySince: + days: 30 + actions: + - addReply: + reply: "Closing issue due to no activity in 30 days" + - closeIssue diff --git a/.github/workflows/new_stale_close.yml b/.github/workflows/new_stale_close.yml deleted file mode 100644 index 7adcba18957a3..0000000000000 --- a/.github/workflows/new_stale_close.yml +++ /dev/null @@ -1,21 +0,0 @@ -name: Close Stale Issues -description: Close stale issues that have not been updated in 30 days -resource: repository -configuration: - resourceManagementConfiguration: - scheduledSearches: - - frequencies: - - daily: - time: 15:00 - filters: - - hasLabel: - label: stale - - isIssue - - isOpen - - isNotAssigned - - noActivitySince: - days: 30 - actions: - - addReply: - reply: "Closing issue due to no activity in 90 days" - - closeIssue