Skip to content

Commit

Permalink
added dropdown in OS field of the bug-report issue form and github wo…
Browse files Browse the repository at this point in the history
…rkflow to auto lable
  • Loading branch information
aman4433 committed Jan 15, 2025
1 parent 1f186ed commit 6d755f2
Show file tree
Hide file tree
Showing 2 changed files with 63 additions and 2 deletions.
33 changes: 31 additions & 2 deletions .github/ISSUE_TEMPLATE/bug-report.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,40 @@ body:
attributes:
value: '### Environment'

- type: textarea
- type: dropdown
id: os
attributes:
label: OS
placeholder: 'printf "$(uname -srm)\n$(cat /etc/os-release)\n"'
options:
- 'RHEL 8'
- 'RHEL 9'
- 'CentOS'
- 'Fedora 41'
- 'Fedora 40'
- 'Ubuntu 24'
- 'Ubuntu 22'
- 'Ubuntu 20'
- 'Debian 12'
- 'Debian 11'
- 'Flatcar Container Linux'
- 'SUSE Linux Enterprise Server (SLES)'
- 'openSUSE Leap'
- 'openSUSE Tumbleweed'
- 'Clear Linux'
- 'Oracle Linux 9'
- 'Oracle Linux 8'
- 'AlmaLinux 9'
- 'AlmaLinux 8'
- 'Rocky Linux 9'
- 'Rocky Linux 8'
- 'Amazon Linux 2023'
- 'Amazon Linux 2'
- 'Kylin Linux Advanced Server'
- 'UOS Linux'
- 'openEuler 24'
- 'openEuler 22'
- 'openEuler 20'
- 'Other|Unsupported'
validations:
required: true

Expand Down
32 changes: 32 additions & 0 deletions .github/workflows/auto-label-os.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Issue labeler
on:
issues:
types: [opened]

permissions:
contents: read

jobs:
label-component:
runs-on: ubuntu-latest
permissions:
issues: write

steps:
- uses: actions/checkout@v3

- name: Parse issue form
uses: stefanbuck/github-issue-parser@v3
id: issue-parser
with:
template-path: .github/ISSUE_TEMPLATE/bug-report.yaml

- name: Set labels based on OS field
uses: redhat-plumbers-in-action/advanced-issue-labeler@v2
with:
issue-form: ${{ steps.issue-parser.outputs.jsonString }}
section: os
block-list: |
None
Other
token: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 6d755f2

Please sign in to comment.