From 860ce36e9ea2f5881cbe256495e2d99e4898761c Mon Sep 17 00:00:00 2001 From: ShaharNaveh <50263213+ShaharNaveh@users.noreply.github.com> Date: Thu, 10 Jul 2025 12:53:48 +0300 Subject: [PATCH] Add "take" comment command --- .github/workflows/comment-commands.yml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 .github/workflows/comment-commands.yml diff --git a/.github/workflows/comment-commands.yml b/.github/workflows/comment-commands.yml new file mode 100644 index 00000000000..2b2a1caefe8 --- /dev/null +++ b/.github/workflows/comment-commands.yml @@ -0,0 +1,24 @@ +name: Comment Commands + +on: + issue_comment: + types: created + +jobs: + issue_assign: + if: (!github.event.issue.pull_request) && github.event.comment.body == 'take' + runs-on: ubuntu-latest + + concurrency: + group: ${{ github.actor }}-issue-assign + + permissions: + issues: write + + steps: + - run: gh issue edit "${{ env.ISSUE_NUMBER }}" --add-assignee "${{ env.USER_LOGIN }}" + env: + ISSUE_NUMBER: ${{ github.event.issue.number }} + USER_LOGIN: ${{ github.event.comment.user.login }} + GH_TOKEN: ${{ github.token }} + GH_REPO: ${{ github.repository }}