[close #528] add workflows to check staleness and PR title (#529)

This commit is contained in:
Jian Zhang 2022-02-21 13:49:17 +08:00 committed by GitHub
parent 49476d7fa0
commit 2ac49bb92c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 34 additions and 1 deletions

View File

@ -1,4 +1,4 @@
name: "Pull Request Labeler"
name: "PR Labeler"
on:
- pull_request_target

14
.github/workflows/pr-title-checker.yml vendored Normal file
View File

@ -0,0 +1,14 @@
name: 'PR Title Checker'
on:
pull_request:
types: [edited, opened, synchronize, reopened]
jobs:
title-check:
runs-on: ubuntu-latest
steps:
- uses: naveenk1223/action-pr-title@master
with:
regex: '\[to|fix|close #[0-9]+\] .+'
prefix_case_sensitive: true
max_length: -1

19
.github/workflows/stale-checker.yml vendored Normal file
View File

@ -0,0 +1,19 @@
name: 'Stale Checker'
on:
schedule:
- cron: '0 0 * * *'
jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v4
with:
days-before-stale: 30
stale-issue-message: 'This issue is stale because it has been open 30 days with no activity.'
stale-issue-label: 'status/stale'
days-before-issue-close: -1
stale-pr-message: 'This PR is stale because it has been open 30 days with no activity. Remove the status/stale label or comment or this PR will be closed in 7 days.'
stale-pr-label: 'status/stale'
days-before-pr-close: 7
close-pr-message: 'This PR was closed because it has been stalled for 7 days with no activity.'