feat(ci): add /claim command to auto-assign issues

This commit is contained in:
t8y2
2026-06-11 00:31:37 +08:00
parent 01975cf1ba
commit 0b8a213fc9
2 changed files with 85 additions and 0 deletions
+26
View File
@@ -0,0 +1,26 @@
name: Issue Claim
on:
issue_comment:
types: [created]
permissions:
contents: read
issues: write
jobs:
claim:
runs-on: ubuntu-latest
if: ${{ !github.event.issue.pull_request }}
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v4
- name: Handle /claim command
run: node .github/scripts/issue-claim.mjs
env:
ISSUE_NUMBER: ${{ github.event.issue.number }}
COMMENT_BODY: ${{ github.event.comment.body }}
COMMENT_USER: ${{ github.event.comment.user.login }}
COMMENT_USER_TYPE: ${{ github.event.comment.user.type }}