Skip to content

Dev

Dev #91

Workflow file for this run

name: Greetings
on:
issues:
types: [opened]
pull_request:
types: [opened]
permissions:
issues: write
pull-requests: write
jobs:
greeting:
runs-on: ubuntu-latest
steps:
- name: Send greeting for issues
if: github.event_name == 'issues'
run: |
curl -s -X POST -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
-H "Accept: application/vnd.github.v3+json" \
https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.issue.number }}/comments \
-d '{"body": "Hello @${{ github.actor }}, 👋 Thank you for creating an issue in our repository. We appreciate your contribution!"}'
- name: Send greeting for pull requests
if: github.event_name == 'pull_request'
run: |
curl -s -X POST -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
-H "Accept: application/vnd.github.v3+json" \
https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.pull_request.number }}/comments \
-d '{"body": "Hello @${{ github.actor }}, 👋 Thank you for creating a pull request in our repository. We appreciate your contribution!"}'