Skip to content

Add branch limit

Add branch limit #12

Workflow file for this run

name: Repo cleanup (old PRs, branches and issues)
on:
schedule:
- cron: "0 0 * * *"
# Allow workflow to be manually run from the GitHub UI
workflow_dispatch:
pull_request:
jobs:
cleanup-repository:
runs-on: ubuntu-latest
steps:
# Mark issues and PRs with no activity as stale after a while, and close them after a while longer
- uses: actions/stale@98ed4cb500039dbcccf4bd9bedada4d0187f2757 #v3.0.19
with:
stale-issue-message: 'Marking issue as stale'
stale-pr-message: 'Marking PR as stale'
stale-issue-label: 'stale'
stale-pr-label: 'stale'
days-before-stale: 30
days-before-close: 7
- name: Checkout
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 #v3.6.0
- uses: ./
with:
github_token: ${{ github.token }}
last_commit_age_days: 100
dry_run: yes
ignore_branches: test_prefix/one,test_prefix/two,test_prefix_ignored/one
branch_limit: 1