Skip to content

Light theme

Light theme #15

Workflow file for this run

name: Greet New PRs and Issues
on:
pull_request:
types: [opened]
issues:
types: [opened]
permissions:
issues: write
pull-requests: write
jobs:
greet:
runs-on: ubuntu-latest
steps:
- name: Greet on PRs and Issues
uses: actions/github-script@v6
with:
script: |
const isPR = context.payload.pull_request !== undefined;
const number = isPR ? context.payload.pull_request.number : context.payload.issue.number;
const commentBody = isPR
? `Hey there! 👋 Thanks for taking the time to send in this pull request. We are happy to have your contribution! If you have any questions or need any help, feel free to ask.`
: `Hello! 👋 Thanks for opening this issue. We appreciate your feedback and will look into it as soon as possible. Feel free to add more details if necessary.`;
await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: number,
body: commentBody
});