Skip to content

Update self-assign.yml #2

Update self-assign.yml

Update self-assign.yml #2

Workflow file for this run

name: Comment on New Issues
on:
issues:
types: [opened]
permissions:
issues: write # Ensure the workflow has write permissions for issues
jobs:
comment:
runs-on: ubuntu-latest
steps:
- name: Post a comment on the new issue
uses: actions/github-script@v6
with:
script: |
const issueNumber = context.issue.number;
const commentBody = `Thank you for creating a new issue! 🎉 Your issue is currently under review.
If you would like to assign this issue to yourself, please comment with the word **"self"** and the issue will be assigned to you.`;

Check failure on line 22 in .github/workflows/issue-comment.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/issue-comment.yml

Invalid workflow file

You have an error in your yaml syntax on line 22
await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issueNumber,
body: commentBody
});