name: "Close stale pull requests and issues" on: schedule: - cron: "12 3 * * *" # arbitrary time not to DDOS GitHub permissions: contents: read jobs: stale: permissions: pull-requests: write # required for marking and closing stale PRs issues: write # required for marking and closing stale issues actions: write # required for the stale action to manage (reset) its state cache runs-on: ubuntu-latest steps: - uses: actions/stale@4391f3da665fdf50b6810c1a66712fb9ba21aa93 # v11.0.0 with: repo-token: ${{ secrets.GITHUB_TOKEN }} stale-pr-message: 'This PR was marked stale. It will be closed in 14 days without additional activity.' close-pr-message: 'Closed as inactive. Feel free to reopen if this PR is still being worked on.' exempt-pr-labels: 'release:after-ga' stale-issue-message: 'This issue was marked stale due to lack of activity. Please leave a comment if you would like to keep this issue open.' close-issue-message: | Closed due to inactivity. We appreciate your input, and if this issue is still relevant, please reopen it, or comment "/reopen" and we'll do it for you. Thank you for your contribution! # applies only to pull requests days-before-pr-stale: 14 days-before-pr-close: 14 # applies only to issues days-before-issue-stale: 365 days-before-issue-close: 14 # TODO: remove or lower once we process through old issues backlog # defaults to 30 operations per run, empirically ~12 issues or PRs. operations-per-run: 100