Skip to content

Commit

Permalink
chore: close inactive PRs and allow manual trigger (#17220)
Browse files Browse the repository at this point in the history
  • Loading branch information
fuyufjh authored Jun 12, 2024
1 parent 6ab7752 commit c491b46
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions .github/workflows/stale.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,23 @@ name: Mark stale issues and pull requests
on:
schedule:
- cron: '30 1 * * *'
workflow_dispatch:
inputs:
# https://github.com/marketplace/actions/close-stale-issues#operations-per-run
operationsPerRun:
description: 'Max number of operations per run'
required: true
default: 30

jobs:
stale:

runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write

steps:
- uses: actions/stale@v5
- uses: actions/stale@v9
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-issue-message: >
Expand All @@ -25,3 +31,6 @@ jobs:
stale-issue-label: 'no-issue-activity'
stale-pr-label: 'no-pr-activity'
days-before-close: -1
days-before-pr-close: 7
operations-per-run: ${{ github.event.inputs.operationsPerRun }}
enable-statistics: true

0 comments on commit c491b46

Please sign in to comment.