[WordCamp] Gdynia, Poland #30
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: Issue labeler | |
on: | |
issues: | |
types: [opened] | |
permissions: | |
contents: read | |
jobs: | |
label-component: | |
runs-on: ubuntu-latest | |
permissions: | |
# required for all workflows | |
issues: write | |
steps: | |
- uses: actions/checkout@v4.1.1 | |
- name: Parse issue form | |
uses: stefanbuck/github-issue-parser@v3.1.0 | |
id: issue-parser | |
with: | |
template-path: .github/ISSUE_TEMPLATE/0-event-application-vetting.yml | |
- run: cat ${HOME}/issue-parser-result.json | |
- run: echo $EVENTTYPE $EVENTNAME | |
env: | |
EVENTTYPE: ${{ steps.issue-parser.outputs.issueparser_eventtype }} | |
EVENTNAME: ${{ steps.issue-parser.outputs.issueparser_eventname }} | |
- name: Set labels based on Event Type field | |
uses: redhat-plumbers-in-action/advanced-issue-labeler@v3.0.0 | |
with: | |
issue-form: ${{ steps.issue-parser.outputs.jsonString }} | |
section: eventtype | |
config-path: .github/label-policy.yml | |
block-list: | | |
None | |
Other | |
token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Greet first time contributors | |
uses: actions/first-interaction@v1 | |
with: | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
issue-message: "@{{ issue.user.login }} Thank you for contributing your first issue to the WordPress Community team" | |
- uses: actions/github-script@v7.0.1 | |
with: | |
script: | | |
github.rest.issues.createComment({ | |
issue_number: context.issue.number, | |
owner: context.repo.owner, | |
repo: context.repo.repo, | |
body: "Heads up @WordPress/community-triage, we have a new issue openned by @${{ github.event.issue.user.login }}. Time to triage." | |
}) |