2021-12-16 19:19:11 +00:00
name : Mark stale issues
on :
schedule :
2022-07-03 12:37:47 +00:00
- cron : '0 8 * * *'
2022-01-08 09:42:35 +00:00
workflow_dispatch :
2023-04-15 08:28:39 +00:00
issue_comment :
2021-12-16 19:19:11 +00:00
jobs :
2023-04-16 12:39:13 +00:00
stale_action :
if : github.event_name != 'issue_comment'
2021-12-16 19:19:11 +00:00
runs-on : ubuntu-latest
permissions :
issues : write
steps :
2022-12-24 10:00:43 +00:00
- uses : actions/stale@v7.0.0
2022-07-07 18:05:27 +00:00
with :
repo-token : ${{ secrets.GITHUB_TOKEN }}
days-before-stale : 30
days-before-close : 5
stale-issue-message : 'This issue is stale because it has been open 30 days with no activity. Please comment or update this issue or it will be closed in 5 days.'
stale-issue-label : 'stale'
exempt-issue-labels: 'Internal, Fixed in next release, Bug : Confirmed, Documentation Needed'
exempt-all-issue-assignees : true
operations-per-run : 300
close-issue-reason : 'not_planned'
2023-04-16 12:39:13 +00:00
remove_stale : # trigger "stale" removal immediately when stale issues are commented on
if : github.event_name == 'issue_comment'
permissions :
contents : read # for actions/checkout
issues : write # to edit issues label
runs-on : ubuntu-latest
steps :
- name : Checkout
uses : actions/checkout@v3.4.0
- name : Remove 'stale' label
run : gh issue edit ${{ github.event.issue.number }} --remove-label 'stale'
env :
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}