-
Notifications
You must be signed in to change notification settings - Fork 14
add workflow to label issues as stale #695
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
| name: Stale issues | ||
|
|
||
| on: | ||
| workflow_dispatch: | ||
| schedule: | ||
| - cron: "21 4 * * *" | ||
|
|
||
| jobs: | ||
| stale: | ||
| permissions: | ||
| actions: write | ||
| issues: write | ||
| runs-on: ubuntu-latest | ||
|
|
||
| steps: | ||
| - uses: actions/stale@v10 | ||
| with: | ||
| stale-issue-message: 'This issue is stale because it has been open 90 days with no activity. This issue will be closed in 30 days unless new comments are made or the stale label is removed. To skip these checks, apply the "feature, enhancement or lifecycle/frozen" labels.' | ||
| stale-issue-label: 'lifecycle/stale' | ||
| exempt-issue-labels: 'lifecycle/frozen,feature,enhancement' | ||
|
Comment on lines
+10
to
+20
|
||
| days-before-stale: 90 | ||
| close-issue-message: 'This issue was automatically closed due to inactivity.' | ||
| days-before-issue-close: 30 | ||
| remove-stale-when-updated: true | ||
| operations-per-run: 300 | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The job requests
actions: write, butactions/staleonly needs to read/update issues (and optionally pull requests). Grantingactions: writeis broader than necessary; please remove it to follow least-privilege permissions.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is intentional as its required to clean stale cache. See actions/stale#1248