From 72827ef003886aa819085288668fab1918ab9d6a Mon Sep 17 00:00:00 2001 From: Krishivag Date: Mon, 18 May 2026 22:07:25 +0530 Subject: [PATCH 1/3] feat(ci): add stale PR reminder workflow Add a scheduled GitHub Actions workflow using actions/stale@v9 that checks open PRs for inactivity. - After 7 days with no push or comment: posts a check-in comment - After 14 days (7+7): adds a stale label - Never auto-closes PRs - Removes stale label when activity resumes - Exempts PRs labeled pinned or work-in-progress Closes #163 --- .github/workflows/stale.yml | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 .github/workflows/stale.yml diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml new file mode 100644 index 0000000..74c316c --- /dev/null +++ b/.github/workflows/stale.yml @@ -0,0 +1,36 @@ +name: Stale PRs + +on: + schedule: + # Run daily at 09:00 UTC + - cron: '0 9 * * *' + workflow_dispatch: + +permissions: + pull-requests: write + issues: write + +jobs: + stale: + runs-on: ubuntu-latest + timeout-minutes: 5 + steps: + - uses: actions/stale@v9 + with: + # Only target pull requests, not issues + stale-issue-message: '' + stale-pr-message: > + This PR has had no activity for 7 days. + Are you still working on it? + If so, please push an update or leave a comment. + Otherwise it will be labeled `stale` in another 7 days. + days-before-stale: 7 + days-before-close: -1 + stale-pr-label: stale + exempt-pr-labels: 'pinned,work-in-progress' + only-pr-labels: '' + operations-per-run: 100 + # Disable issue handling entirely + days-before-issue-stale: -1 + days-before-issue-close: -1 + remove-stale-when-updated: true From ebb64610ed7fe797098df0179c91ba594eabfdd4 Mon Sep 17 00:00:00 2001 From: Krishivag Date: Thu, 21 May 2026 11:11:00 +0530 Subject: [PATCH 2/3] fix(ci): implement staggered 7-then-14 day stale behavior and tighten permissions --- .github/workflows/stale.yml | 27 +++++++++++++++++++++++---- 1 file changed, 23 insertions(+), 4 deletions(-) diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index 74c316c..233e52f 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -8,17 +8,15 @@ on: permissions: pull-requests: write - issues: write jobs: - stale: + # Job 1: Post a check-in comment after 7 days of inactivity (no label yet) + check-in: runs-on: ubuntu-latest timeout-minutes: 5 steps: - uses: actions/stale@v9 with: - # Only target pull requests, not issues - stale-issue-message: '' stale-pr-message: > This PR has had no activity for 7 days. Are you still working on it? @@ -26,11 +24,32 @@ jobs: Otherwise it will be labeled `stale` in another 7 days. days-before-stale: 7 days-before-close: -1 + stale-pr-label: '' + exempt-pr-labels: 'pinned,work-in-progress' + only-pr-labels: '' + operations-per-run: 100 + # Disable issue handling entirely + stale-issue-message: '' + days-before-issue-stale: -1 + days-before-issue-close: -1 + remove-stale-when-updated: true + + # Job 2: Apply the stale label after 14 days of inactivity + label-stale: + runs-on: ubuntu-latest + timeout-minutes: 5 + steps: + - uses: actions/stale@v9 + with: + stale-pr-message: '' + days-before-stale: 14 + days-before-close: -1 stale-pr-label: stale exempt-pr-labels: 'pinned,work-in-progress' only-pr-labels: '' operations-per-run: 100 # Disable issue handling entirely + stale-issue-message: '' days-before-issue-stale: -1 days-before-issue-close: -1 remove-stale-when-updated: true From b68f72013747af468c5378d4724d7100c389d55e Mon Sep 17 00:00:00 2001 From: Krishivag Date: Thu, 21 May 2026 12:59:00 +0530 Subject: [PATCH 3/3] fix(ci): fix stale-pr-label for job 1 --- .github/workflows/stale.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index 233e52f..ce80a47 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -24,7 +24,7 @@ jobs: Otherwise it will be labeled `stale` in another 7 days. days-before-stale: 7 days-before-close: -1 - stale-pr-label: '' + stale-pr-label: 'stale-warned' exempt-pr-labels: 'pinned,work-in-progress' only-pr-labels: '' operations-per-run: 100