Skip to content

Commit

Permalink
Updated CI
Browse files Browse the repository at this point in the history
  • Loading branch information
ParamThakkar123 committed Oct 18, 2024
1 parent badf24d commit 764ef70
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions .github/workflows/assign-issue.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,20 @@ on:
jobs:
assign-issue:
runs-on: ubuntu-latest
if: github.event.comment.body == '/assign-me'
if: github.event.comment.body == '/assign'
steps:
- name: Assign issue to commenter
uses: actions-ecosystem/action-assign@v1
uses: actions/github-script@v6
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
issue_number: ${{ github.event.issue.number }}
assignees: ${{ github.event.comment.user.login }}
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const issueNumber = context.payload.issue.number;
const commenter = context.payload.comment.user.login;
// Assign the issue to the commenter
await github.issues.addAssignees({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issueNumber,
assignees: [commenter]
});

0 comments on commit 764ef70

Please sign in to comment.