name: Stale Pull Requests on: schedule: - cron: "30 3 * * *" workflow_dispatch: inputs: mode: description: Run without changes or apply the PR inactivity policy type: choice required: true default: dry-run options: - dry-run - apply permissions: contents: read issues: write pull-requests: write concurrency: group: stale-pull-requests cancel-in-progress: false jobs: stale-prs: name: Check Every Open PR runs-on: ubuntu-latest timeout-minutes: 15 steps: - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0 with: node-version: 24 - name: Check PR inactivity env: GITHUB_TOKEN: ${{ github.token }} GITHUB_REPOSITORY: ${{ github.repository }} RUN_MODE: ${{ github.event_name == 'schedule' && 'apply' || inputs.mode }} run: node scripts/stale-prs/run.mjs "--${RUN_MODE}"