Top banner added #39
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
name: Greet Contributor | |
on: | |
issues: | |
types: [opened] | |
pull_request_target: | |
types: [opened] | |
jobs: | |
welcome-issue: | |
permissions: write-all | |
runs-on: ubuntu-latest | |
if: ${{ github.event_name == 'issues' }} | |
steps: | |
- uses: actions/github-script@v6 | |
if: ${{ github.event.sender.login != github.repository_owner }} | |
with: | |
script: | | |
github.rest.issues.createComment({ | |
issue_number: context.issue.number, | |
owner: context.repo.owner, | |
repo: context.repo.repo, | |
body: `### Hello @${{ github.actor }}, Thank you for raising the issue. | |
Soon the maintainers/owner will review it and offer feedback and suggestions. If you enjoy contributing to the project, please consider giving it a star ⭐.` | |
}) | |
welcome-pull_request: | |
permissions: write-all | |
runs-on: ubuntu-latest | |
if: ${{ github.event_name == 'pull_request_target' }} | |
steps: | |
- uses: actions/github-script@v6 | |
if: ${{ github.event.sender.login != github.repository_owner }} | |
with: | |
script: | | |
github.rest.issues.createComment({ | |
issue_number: context.issue.number, | |
owner: context.repo.owner, | |
repo: context.repo.repo, | |
body: `### Hello @${{ github.actor }}, Thank you for raising a pull request. | |
Soon the maintainers/owner will review it and offer feedback and suggestions. If you enjoy contributing to the project, please consider giving it a star ⭐.` | |
}) | |