[meta] Implement label-commenter (#921)

* Update incomplete-pr.yaml

* Update workflows

Signed-off-by: Bᴇʀɴᴅ Sᴄʜᴏʀɢᴇʀs <me@bjw-s.dev>

* Update workflows

Signed-off-by: Bᴇʀɴᴅ Sᴄʜᴏʀɢᴇʀs <me@bjw-s.dev>
This commit is contained in:
Bᴇʀɴᴅ Sᴄʜᴏʀɢᴇʀs 2021-05-20 09:51:03 +02:00 committed by GitHub
parent 6fd1f76c34
commit 76ab38c293
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 61 additions and 68 deletions

29
.github/label-commenter-config.yml vendored Normal file
View File

@ -0,0 +1,29 @@
---
labels:
- name: kind:invalid-template
labeled:
issue:
body: |
:wave: @{{ issue.user.login }}, please follow the template provided.
action: close
locking: lock
lock_reason: resolved
- name: kind:support
labeled:
issue:
body: |
:wave: @{issue-author}, we use the issue tracker exclusively
for bug reports and feature requests. However, this issue appears
to be a support request. Please use our support channels
to get help.
- [Docs](https://docs.k8s-at-home.com/)
- [Discord](https://discord.gg/sTMX7Vh)
- [GitHub Discussions](https://github.com/k8s-at-home/organization/discussions)
action: close
- name: kind:incomplete-pr
labeled:
pr:
body: |
:wave: @{{ pull_request.user.login }}, thanks for taking the time to submit this PR. 🙏🏽 Would you mind updating the `version` in `Chart.yaml` per [semver](http://semver.org/) and then update `README_CHANGELOG.md.gotmpl` and run `./hack/gen-helm-docs.sh stable <chart>` again?

View File

@ -1,20 +0,0 @@
---
name: 'Incomplete PR'
on:
issues:
types: [labeled, unlabeled, reopened]
jobs:
support:
runs-on: ubuntu-20.04
steps:
- uses: dessant/support-requests@v2
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
support-label: 'kind:incomplete-pr'
issue-comment: >
:wave: @{issue-author}, thanks for taking the time to submit this PR. 🙏🏽 Would you mind updating the `version` in `Chart.yaml` per [semver](http://semver.org/) and then update `README_CHANGELOG.md.gotmpl` and run `./hack/gen-helm-docs.sh stable <chart>` again?
close-issue: false
lock-issue: false

View File

@ -1,21 +0,0 @@
---
name: 'Invalid Template'
on:
issues:
types: [labeled, unlabeled, reopened]
jobs:
support:
runs-on: ubuntu-20.04
steps:
- uses: dessant/support-requests@v2
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
support-label: 'kind:invalid-template'
issue-comment: >
:wave: @{issue-author}, please follow the template provided.
close-issue: true
lock-issue: true
issue-lock-reason: 'resolved'

32
.github/workflows/label-commenter.yaml vendored Normal file
View File

@ -0,0 +1,32 @@
---
name: 'Label Commenter'
on:
issues:
types:
- labeled
- unlabeled
pull_request_target:
types:
- labeled
- unlabeled
permissions:
contents: read
issues: write
pull-requests: write
permissions:
contents: read
pull-requests: write
jobs:
support:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
with:
ref: main # Set your default branch
- name: Label Commenter
uses: peaceiris/actions-label-commenter@v1

View File

@ -1,27 +0,0 @@
---
name: 'Support requests'
on:
issues:
types: [labeled, unlabeled, reopened]
jobs:
support:
runs-on: ubuntu-20.04
steps:
- uses: dessant/support-requests@v2
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
support-label: 'kind:support'
issue-comment: >
:wave: @{issue-author}, we use the issue tracker exclusively
for bug reports and feature requests. However, this issue appears
to be a support request. Please use our support channels
to get help.
- [Docs](https://docs.k8s-at-home.com/)
- [Discord](https://discord.gg/sTMX7Vh)
- [GitHub Discussions](https://github.com/k8s-at-home/organization/discussions)
close-issue: true
lock-issue: false
issue-lock-reason: 'off-topic'