Skip to content

Commit

Permalink
[CI] Add PR labeler (openvinotoolkit#994)
Browse files Browse the repository at this point in the history
* add PR labeler

* add token

* add labeler based on changed files

* correct paths

* better names

* add fix and dependencies labels
  • Loading branch information
akashchi authored Apr 9, 2023
1 parent 4348dd8 commit c7c4230
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 0 deletions.
18 changes: 18 additions & 0 deletions .github/labeler_files.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
labeler-strategy: append # only add new labels, never remove already assigned

new notebook:
- files:
added: notebooks/**/*.ipynb
enhancement:
- files:
modified: notebooks/**/*
added: notebooks/**/*
documentation:
- files:
modified: "**/*.md"
added: "**/*.md"
dependencies:
- files:
added: "**/*requirements*"
modified: "**/*requirements*"
modified: "**/Pipfile*"
4 changes: 4 additions & 0 deletions .github/labeler_regexp.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
gsoc:
- '/gsoc|summer/i'
fix:
- '/bug|not working|fail|fails|error|issue/i'
24 changes: 24 additions & 0 deletions .github/workflows/labeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: "PR Labeler"
on:
pull_request:
types: [opened, edited]

jobs:
labelling:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Add labels (Title/Description)
uses: github/[email protected]
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
configuration-path: ".github/labeler_regexp.yml"
not-before: 2023-03-30T00:00:00Z
enable-versioned-regex: 0
include-title: 1
sync-labels: 1
- name: Add labels (Changed Files)
uses: doka-guide/[email protected]
with:
token: "${{ secrets.GITHUB_TOKEN }}"
config: ".github/labeler_files.yml"

0 comments on commit c7c4230

Please sign in to comment.