Skip to content

Commit 1981ca7

Browse files
Add workflow to automatically close stale issues and PRs
1 parent 6ca9c80 commit 1981ca7

1 file changed

Lines changed: 32 additions & 0 deletions

File tree

.github/workflows/stale.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: "Close stale issues and PRs"
2+
3+
on:
4+
schedule:
5+
- cron: "0 0 * * *" # every day at 00:00 UTC
6+
7+
permissions:
8+
issues: write
9+
pull-requests: write
10+
11+
env:
12+
STALE_LABEL: inactive
13+
EXEMPT_LABELS: "pending,planning,in progress"
14+
MESSAGE: >
15+
This conversation has been automatically marked as stale because it has not had recent activity.
16+
It will be closed if no further activity occurs.
17+
Thank you for your contributions.
18+
19+
jobs:
20+
stale:
21+
runs-on: ubuntu-latest
22+
steps:
23+
- uses: actions/stale@v9
24+
with:
25+
# 60 days before marking issues/PRs stale
26+
days-before-close: -1 # does not close automatically
27+
stale-issue-label: ${{ env.STALE_LABEL }}
28+
exempt-issue-labels: ${{ env.EXEMPT_LABELS }}
29+
stale-issue-message: ${{ env.MESSAGE }}
30+
stale-pr-label: ${{ env.STALE_LABEL }}
31+
exempt-pr-labels: ${{ env.EXEMPT_LABELS }}
32+
stale-pr-message: ${{ env.MESSAGE }}

0 commit comments

Comments
 (0)