Skip to content

Commit 6bcf40c

Browse files
authored
Add Auto Labeler for issues (#847)
* feat: add differnet versions of workflow * fix: use npx over npm i -g * feat: add myself as contributor * ci: update home repo * feat: issue labeler * ci: test github labeler * fix: indentations man * ci: test github labeler * ci: test github labeler * ci: test github labeler * ci: test github labeler * ci: test github labeler * ci: test github labeler
1 parent 41b9e86 commit 6bcf40c

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

.github/workflows/issue_comment.yml

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: Add Label with Comment
2+
3+
on: [issue_comment]
4+
5+
jobs:
6+
create_comment:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions-ecosystem/action-regex-match@v2
10+
id: regex-match
11+
with:
12+
text: ${{ github.event.comment.body }}
13+
regex: '\[lang:\s*(.*?)\s*\]'
14+
15+
- uses: actions-ecosystem/action-add-labels@v1
16+
if: ${{ steps.regex-match.outputs.match != '' }}
17+
with:
18+
github_token: ${{ secrets.GITHUB_TOKEN }}
19+
labels: "lang: ${{ steps.regex-match.outputs.group1 }}"

0 commit comments

Comments
 (0)