From 2ad607fa2d18d2d848b39daa24acb818c958a050 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Tue, 21 Jan 2025 13:47:56 +1100 Subject: [PATCH] Create auto-close-issues.yml Signed-off-by: David Bomba --- .github/workflows/auto-close-issues.yml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 .github/workflows/auto-close-issues.yml diff --git a/.github/workflows/auto-close-issues.yml b/.github/workflows/auto-close-issues.yml new file mode 100644 index 0000000..f767895 --- /dev/null +++ b/.github/workflows/auto-close-issues.yml @@ -0,0 +1,21 @@ +name: Close stale issues after 5 days + +on: + schedule: + # Run this workflow every day at midnight + - cron: '0 0 * * *' + +jobs: + close-stale-issues: + runs-on: ubuntu-latest + steps: + - name: Close stale issues + uses: actions/stale@v7 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + stale-issue-message: "This issue has been automatically closed due to inactivity for 5 days." + days-before-stale: 4 # Number of days before marking an issue as stale + days-before-close: 1 # Number of days after being marked stale before closing + stale-label: "stale" # Label to add to stale issues + exempt-issue-labels: "keep-open,triage,bug" # Prevents issues with this label from being closed + only-issues: true # Only affects issues, not pull requests