Skip to content

Commit

Permalink
ci: label issues based on type
Browse files Browse the repository at this point in the history
  • Loading branch information
jamacku authored and zmiklank committed May 6, 2024
1 parent 22c8401 commit 5e49921
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 0 deletions.
13 changes: 13 additions & 0 deletions .github/advanced-issue-labeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
policy:
- section:
- id: ['type']
block-list: ['Other', 'None']
label:
- name: 'type: bug'
keys: ['Bug Report']

- name: 'type: feature'
keys: ['Feature Request']

- name: 'type: question'
keys: ['Question']
29 changes: 29 additions & 0 deletions .github/workflows/issue-labeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Issue labeler
on:
issues:
types: [ opened ]

permissions:
contents: read

jobs:
label-issues:
runs-on: ubuntu-latest

permissions:
issues: write

steps:
- uses: actions/checkout@v4

- name: Parse issue form
uses: stefanbuck/github-issue-parser@v3
id: issue-parser
with:
template-path: .github/ISSUE_TEMPLATE/tfaga-issue.yml

- name: Set labels based on type input
uses: redhat-plumbers-in-action/advanced-issue-labeler@v3
with:
issue-form: ${{ steps.issue-parser.outputs.jsonString }}
token: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 5e49921

Please sign in to comment.