Skip to content

Commit cc9e042

Browse files
dev: stale issue & pr scheduled check (monthly)
1 parent 2e9294b commit cc9e042

File tree

2 files changed

+43
-0
lines changed

2 files changed

+43
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# ----------------------------------------
2+
# Scheduled stale issue & pull request check
3+
#
4+
# Adds 'stale' label after a set piece of time,
5+
# then closes stale issues & pull requests a short period after
6+
#
7+
# Using "Close Stale Issues" action
8+
# https://github.com/marketplace/actions/close-stale-issues
9+
# ----------------------------------------
10+
11+
name: 'Scheduled stale check'
12+
on:
13+
workflow_dispatch:
14+
schedule:
15+
- cron: "0 1 1 * *" # at 01:00 on first day of month
16+
17+
jobs:
18+
stale:
19+
runs-on: ubuntu-latest
20+
steps:
21+
- run: echo "🚀 Job automatically triggered by ${{ github.event_name }}"
22+
- run: echo "🐧 Job running on ${{ runner.os }} server"
23+
- run: echo "🐙 Using ${{ github.ref }} branch from ${{ github.repository }} repository"
24+
25+
- uses: actions/stale@v9
26+
with:
27+
stale-issue-message: 'After 30 days with no activity, the issue was automatically marked stale. Remove stale label or add a comment to prevent the issue being closed in 5 days.'
28+
stale-pr-message: 'After 45 days with no activity, the Pull Request was automatically marked stale. Remove stale label or comment to prevent the PR being closed in 10 days.'
29+
close-issue-message: 'This issue was closed because it has been stalled for 5 days with no activity.'
30+
close-pr-message: 'This PR was closed because it has been stalled for 10 days with no activity.'
31+
days-before-issue-stale: 30
32+
days-before-pr-stale: 45
33+
days-before-issue-close: 5
34+
days-before-pr-close: 10
35+
start-date: '2025-04-05T00:00:00Z' # only affect issues/PRs from date created (ISO 8601 or RFC 2822 format)
36+
any-of-labels: 'future,keep' # labels to keep
37+
exempt-issue-assignees: 'practicalli-johnny'
38+
exempt-pr-assignees: 'practicalli-johnny'
39+
40+
# Summary
41+
- run: echo "🎨 Issues & Pull Request checked with actions/stale"
42+
- run: echo "🍏 Job status is ${{ job.status }}."

CHANGELOG.md

+1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
- writing-tips: examples of annotations within admonitions
1313
- mkdocs: round corners style for buttons etc
1414
- intro: add code of respect
15+
- dev: stale issue & pr scheduled check (monthly)
1516

1617
## Changed
1718
- mkdocs: correct github url for repo and edit link

0 commit comments

Comments
 (0)