1+ # This is the main TriageOps workflow for automated issue management here at my public inbox
2+ # on GitHub.
3+ name : TriageOps
4+
5+ on :
6+ issues :
7+ types : [opened, edited, reopened, labeled, unlabeled, assigned, unassigned, closed]
8+ issue_comment :
9+ types : [created]
10+ schedule :
11+ - cron : " 0 7 * * *"
12+
13+ # While these permissions for the GITHUB_TOKEN are unused due to us using our own
14+ # app token generated through actions/create-github-app-token, they are still required
15+ # to silence security warnings about missing explicit permissions.
16+ permissions :
17+ actions : write
18+ contents : write # only for delete-branch option
19+ issues : write
20+ pull-requests : write
21+
22+ jobs :
23+ stale :
24+ name : Manage stale issues
25+ runs-on : ubuntu-latest
26+ if : github.event_name == 'schedule' || (github.event_name == 'issues' && github.event.action != 'labeled') || (github.event_name == 'issue_comment' && github.event.action == 'created')
27+ steps :
28+ - name : Download .env.ci from central repo
29+ run : wget -O .env.ci https://github.com/andreijiroh-dev/dotenvx-secretstore/raw/main/.env.ci
30+ - name : Load secrets via dotenvx
31+ uses : andreijiroh-dev/dotenvx-action@main
32+ with :
33+ path : .env.ci
34+ key : ${{ secrets.DOTENV_META_SECRETS_KEY_CI }}
35+ id : dotenvx
36+ - name : Provision GitHub app token
37+ uses : actions/create-github-app-token@v2
38+ with :
39+ app-id : ${{ steps.dotenvx.outputs.GH_APP_ID }}
40+ private-key : ${{ steps.dotenvx.outputs.GH_APP_KEY }}
41+ - name : Close stale issues
42+ uses : actions/stale@v9
43+ with :
44+ repo-token : ${{ secrets.GITHUB_TOKEN }}
45+ days-before-stale : 14
46+ days-before-close : 7
47+ stale-issue-label : ' stale'
48+ exempt-issue-labels : ' question,personal-stuff,help wanted,stale-exempt'
49+ start-date : " 2025-07-27"
50+ enable-statistics : ' true'
51+ stale-issue-message : |
52+ This issue is being marked as stale due to inactivity in the past 14 days.
53+ It will be closed in the next 7 days if no further activity occurs, and may
54+ be locked manually at the discretion of @ajhalili2006 (and other maintainers).
55+ close-issue-message : |
56+ This issue is now closed due to being stale in the last 21 days. You may
57+ reopen this issue anytime unless it is manually locked.
58+ stale-pr-message : |
59+ This merge request is being marked as stale due to inactivity in the past 14 days.
60+ It will be closed in the next 7 days if no further activity occurs, and may
61+ be locked manually at the discretion of @ajhalili2006 (and other maintainers).
62+ close-pr-message : |
63+ This merge request is now closed due to being stale in the last 21 days. You may
64+ reopen this merge request anytime if you don't delete your branch unless it is
65+ manually locked.
0 commit comments