Implement Auto-Labeling Workflow for GitHub #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# .github/workflows/auto-comment-prs.yml | |
name: Auto Comment on PR | |
on: | |
pull_request: | |
types: [opened] | |
jobs: | |
comment: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Comment on PR | |
uses: actions/github-script@v5 | |
with: | |
script: | | |
github.rest.issues.createComment({ | |
issue_number: context.payload.pull_request.number, | |
owner: context.repo.owner, | |
repo: context.repo.repo, | |
body: 'Thanks for the PR! We will review it shortly.' | |
}); | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |