Skip to content

Commit

Permalink
Merge pull request #730 from forcedotcom/hknokh-patch-3
Browse files Browse the repository at this point in the history
Create issue-response-handler.yml
  • Loading branch information
hknokh authored Apr 30, 2024
2 parents fa88d8a + 23a66c6 commit d91135a
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/issue-response-handler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Issue Response Handler

on:
issues:
types: [opened]

jobs:
respond:
runs-on: ubuntu-latest
steps:
- name: Post Comment for 'bug'
if: contains(github.event.issue.labels.*.name, 'bug')
run: |
curl -X POST \
-H "Authorization: token ${{ secrets.REPO_TOKEN }}" \
-H "Accept: application/vnd.github.v3+json" \
-d '{"body":"Hello, @${{ github.event.issue.user.login }}\nThank you for reporting a bug. I will take a look at it as soon as possible and let you know of any updates.\nCheers"}' \
https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.issue.number }}/comments
- name: Post Comment for 'feature-request'
if: contains(github.event.issue.labels.*.name, 'feature-request')
run: |
curl -X POST \
-H "Authorization: token ${{ secrets.REPO_TOKEN }}" \
-H "Accept: application/vnd.github.v3+json" \
-d '{"body":"Hello, @${{ github.event.issue.user.login }}\nThank you for your feature request. I will review it as soon as possible and provide updates as they become available.\nCheers"}' \
https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.issue.number }}/comments
- name: Post Comment for 'help-wanted'
if: contains(github.event.issue.labels.*.name, 'help-wanted')
run: |
curl -X POST \
-H "Authorization: token ${{ secrets.REPO_TOKEN }}" \
-H "Accept: application/vnd.github.v3+json" \
-d '{"body":"Hello, @${{ github.event.issue.user.login }}\nThank you for reaching out. I will do my best to assist you as quickly as possible and will keep you updated on my progress.\nCheers"}' \
https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.issue.number }}/comments

0 comments on commit d91135a

Please sign in to comment.