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

Add the stale action for PRs #390

Closed
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions .github/workflows/stale.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Mark stale PRs and close rotten PRs

on:
schedule:
- cron: "0 0 * * *"

permissions:
contents: read

jobs:
stale:

permissions:
pull-requests: write # for actions/stale to close stale PRs
runs-on: ubuntu-latest

steps:
- uses: actions/stale@v8
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we pin this to the commit hash instead per github security guidelines? https://docs.github.com/en/actions/security-guides/security-hardening-for-github-actions#using-third-party-actions

with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-pr-message: "A friendly reminder that this PR had no activity for 90 days. Stale PRs will be closed after an additional 30 days of inactivity."
close-pr-message: "This PR was closed because it has been inactive for 60 days since being marked as stale."
days-before-stale: 90
days-before-close: 60
stale-pr-label: 'lifecycle/stale'
exempt-pr-labels: 'lifecycle/frozen'
close-pr-label: 'lifecycle/rotten'
start-date: '2023-03-16T00:00:00Z'