813443b206
- Add more events to the issue interceptor - Reduce issue label
20 lines
767 B
YAML
20 lines
767 B
YAML
name: "Intercept bad issue/PRs"
|
|
|
|
on:
|
|
issues:
|
|
types: [opened, reopened]
|
|
pull_request:
|
|
types: [opened, reopened]
|
|
|
|
jobs:
|
|
autoclose:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Auto close issues/pr that did not follow template
|
|
uses: roots/issue-closer@v1.1
|
|
with:
|
|
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
|
issue-pattern: "\\[x\\] I have read"
|
|
issue-close-message: ":wave: Hi @${issue.user.login},\n\nThis issue is being automatically closed because it does not follow the issue template."
|
|
pr-pattern: "\\[x\\] Bug|\\[x\\] New feat|\\[x\\] Break|\\[x\\] Doc"
|
|
pr-close-message: ":wave: Hi @${pull_request.user.login},\n\nThis PR is being automatically closed because it does not follow the PR template."
|