Use mitchellh/vouch

This commit is contained in:
Mitchell Hashimoto
2026-02-10 15:44:30 -08:00
parent 5e22d4b01d
commit ad6921f276
4 changed files with 72 additions and 3 deletions

6
.github/VOUCHED.td vendored
View File

@@ -15,7 +15,7 @@
# - To denounce a user, prefix with minus: `-username` or `-platform:username`.
# - Optionally, add comments after a space following the handle.
#
# Maintainers can vouch for new contributors by commenting "lgtm" on an
# issue by the author. Maintainers can denounce users by commenting
# "denounce" or "denounce [username]" on an issue or PR.
# Maintainers can vouch for new contributors by commenting "!vouch" on a
# discussion by the author. Maintainers can denounce users by commenting
# "!denounce" or "!denounce [username]" on a discussion.
mitchellh

20
.github/workflows/vouch-check-issue.yml vendored Normal file
View File

@@ -0,0 +1,20 @@
on:
issues:
types: [opened, reopened]
name: "Vouch - Check Issue"
permissions:
contents: read
issues: write
jobs:
check:
runs-on: namespace-profile-ghostty-xsm
steps:
- uses: mitchellh/vouch/action/check-issue@v1
with:
issue-number: ${{ github.event.issue.number }}
auto-close: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

20
.github/workflows/vouch-check-pr.yml vendored Normal file
View File

@@ -0,0 +1,20 @@
on:
pull_request_target:
types: [opened, reopened]
name: "Vouch - Check PR"
permissions:
contents: read
pull-requests: write
jobs:
check:
runs-on: namespace-profile-ghostty-xsm
steps:
- uses: mitchellh/vouch/action/check-pr@v1
with:
pr-number: ${{ github.event.pull_request.number }}
auto-close: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

View File

@@ -0,0 +1,29 @@
on:
discussion_comment:
types: [created]
name: "Vouch - Manage by Discussion"
concurrency:
group: vouch-manage
cancel-in-progress: false
permissions:
contents: write
discussions: write
jobs:
manage:
runs-on: namespace-profile-ghostty-xsm
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: mitchellh/vouch/action/manage-by-discussion@v1
with:
discussion-number: ${{ github.event.discussion.number }}
comment-node-id: ${{ github.event.comment.node_id }}
vouch-keyword: "!vouch"
denounce-keyword: "!denounce"
unvouch-keyword: "!unvouch"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}