Skip to content

Mark and close stale pull requests #18

Mark and close stale pull requests

Mark and close stale pull requests #18

Workflow file for this run

# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
name: Mark and close stale pull requests
on:
schedule:
- cron: '30 3 * * *' # Run at 3:30 UTC nightly
workflow_dispatch:
inputs:
dryRun:
description: 'Dry run'
required: true
default: true
type: boolean
operationsPerRun:
description: 'Max GitHub API operations'
required: true
default: 30
type: number
permissions: read-all
jobs:
stale:
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
steps:
- uses: actions/stale@v9
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-pr-message: 'This pull request has been marked as stale due to 30 days of inactivity. It will be closed in 90 days if no further activity occurs. If you think that’s incorrect or this pull request requires a review, please simply write any comment. If closed, you can revive the PR at any time and @mention a reviewer or discuss it on the [email protected] list. Thank you for your contributions.'
close-pr-message: 'This pull request has been closed due to lack of activity. If you think that is incorrect, or the pull request requires review, you can revive the PR at any time.'
stale-pr-label: 'stale'
days-before-pr-stale: 30
days-before-pr-close: 90
days-before-issue-close: -1
days-before-issue-stale: -1
exempt-pr-labels: "pinned"
debug-only: ${{ inputs.dryRun || false }}
operations-per-run: ${{ inputs.operationsPerRun || 100 }}