Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stale bot #2842

Open
wants to merge 11 commits into
base: master
Choose a base branch
from
37 changes: 37 additions & 0 deletions .github/workflows/automate-stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: 'Automation - Stale issues and PRs'

on:
schedule:
- cron: '0 7 * * 1-5'

env:
DAYS_BEFORE_STALE: 30
DAYS_BEFORE_CLOSE: 14

jobs:
stale:
runs-on: ubuntu-latest
permissions:
pull-requests: write
steps:
- name: Run Stale Bot
id: stale-bot
uses: actions/stale@v9
with:
# General settings
days-before-stale: ${{ env.DAYS_BEFORE_STALE }}
days-before-close: ${{ env.DAYS_BEFORE_CLOSE }}
operations-per-run: 3000
enable-statistics: true # This is only useful if secret ACTIONS_STEP_DEBUG=true
remove-stale-when-updated: true

# PR settings
stale-pr-label: stale
kkawula marked this conversation as resolved.
Show resolved Hide resolved
stale-pr-message: |
Hi! This pull request hasn't had any activity for a while, so I am
marking it as stale. It will close in ${{ env.DAYS_BEFORE_CLOSE }}
days if it is not updated. Thanks for contributing!
close-pr-message: false

- name: Logs
run: echo ${{ format('{0},{1}', toJSON(steps.stale.outputs.staled-issues-prs), toJSON(steps.stale.outputs.closed-issues-prs)) }}
Loading