Skip to content

Commit 1fca7b9

Browse files
committed
ENH: Add labeler workflow
Add labeler workflow so that a `GitHub` action, triggered when a PR is opened, automatically labels the PR based on the given rules.
1 parent d7f79dc commit 1fca7b9

File tree

2 files changed

+94
-0
lines changed

2 files changed

+94
-0
lines changed

.github/labeler.yml

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
# Commit prefix regexes
2+
type:Compiler:
3+
title: "^COMP:.*"
4+
5+
type:Bug:
6+
title: "^BUG:.*"
7+
8+
area:Documentation:
9+
title: "^DOC:.*"
10+
11+
type:Enhancement:
12+
title: "^ENH:.*"
13+
14+
type:Performance:
15+
title: "^PERF:.*"
16+
17+
type:Style:
18+
title: "^STYLE:.*"
19+
20+
type:Design:
21+
title: "design"
22+
23+
# Filename regexes
24+
area:Appendices:
25+
files:
26+
- "SoftwareGuide/Latex/Appendices/*"
27+
28+
area:Architecture:
29+
files:
30+
- "SoftwareGuide/Latex/Architecture/*"
31+
32+
area:Book:
33+
files:
34+
- "SoftwareGuide/Latex/*.tex"
35+
36+
area:Cover:
37+
files:
38+
- "SoftwareGuide/Cover/*"
39+
40+
area:DesignAndFunctionality:
41+
files:
42+
- "SoftwareGuide/Latex/DesignAndFunctionality/*"
43+
44+
area:DevelopmentGuidelines:
45+
files:
46+
- "SoftwareGuide/Latex/DevelopmentGuidelines/*"
47+
48+
area:Examples:
49+
files:
50+
- "SoftwareGuide/Examples/*"
51+
52+
area:Introduction:
53+
files:
54+
- "SoftwareGuide/Latex/Introduction/*"
55+
56+
language:C++:
57+
files:
58+
- "*.*.cxx"
59+
60+
language:LaTeX:
61+
files:
62+
- ".*.tex"
63+
64+
language:Python:
65+
files:
66+
- "*.*.py"
67+
68+
type:Artwork:
69+
files:
70+
- "SoftwareGuide/Art/*"
71+
72+
type:BookStyle:
73+
files:
74+
- "Latex/*"
75+
76+
type:Infrastructure:
77+
files:
78+
- ".github/*"
79+
- "CMake/*"
80+
- "Superbuild/*"
81+
- "Utilities/*"

.github/workflows/label-pr.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
name: Label PRs
2+
3+
on:
4+
- pull_request_target
5+
6+
jobs:
7+
build:
8+
runs-on: ubuntu-latest
9+
10+
steps:
11+
- uses: srvaroa/labeler@v0.8
12+
env:
13+
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"

0 commit comments

Comments
 (0)