forked from segmentio/analytics-node
-
Notifications
You must be signed in to change notification settings - Fork 13
40 lines (35 loc) · 1.16 KB
/
housekeeping.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
name: Handle stale PRs
on:
schedule:
- cron: '42 1 * * *'
jobs:
prs:
name: Clean up stale prs
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
steps:
- uses: actions/stale@v7
with:
repo-token: ${{ github.token }}
operations-per-run: 200
stale-pr-message: 'This PR is considered to be stale. It has been open 30 days with no further activity thus it is going to be closed in 10 days. To avoid such a case please consider removing the stale label manually or add a comment to the PR.'
days-before-pr-stale: 30
days-before-pr-close: 10
stale-pr-label: 'Stale'
branches:
name: Cleanup old branches
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Run delete-old-branches-action
uses: beatlabs/delete-old-branches-action@v0.0.9
with:
repo_token: ${{ github.token }}
date: '2 months ago'
dry_run: false
delete_tags: false
extra_protected_branch_regex: ^(main|master|develop)$
exclude_open_pr_branches: true