Skip to content

Commit 4686795

Browse files
authored
Add PR size labeler (#1)
* Add PR checks workflow * pre-commit run on README * try to auto add labels
1 parent 7a04915 commit 4686795

File tree

2 files changed

+34
-2
lines changed

2 files changed

+34
-2
lines changed

.github/workflows/pr-checks.yaml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Checks on PRs
2+
3+
on: [pull_request]
4+
permissions:
5+
issues: write
6+
pull-requests: write
7+
8+
jobs:
9+
labeler:
10+
runs-on: ubuntu-latest
11+
name: Label the PR size
12+
steps:
13+
- uses: codelytv/pr-size-labeler@v1
14+
with:
15+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
16+
xs_label: 'size/xs'
17+
xs_max_size: '10'
18+
s_label: 'size/s'
19+
s_max_size: '100'
20+
m_label: 'size/m'
21+
m_max_size: '500'
22+
l_label: 'size/l'
23+
l_max_size: '1000'
24+
xl_label: 'size/xl'
25+
fail_if_xl: 'True'
26+
message_if_xl: >
27+
This PR exceeds the recommended size of 1000 lines.
28+
Please make sure you are NOT addressing multiple issues with one PR.
29+
Note this PR might be rejected due to its size.
30+
files_to_ignore: ''

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,10 @@ This template, designed as the optimal springboard for your open-source Python r
88
4. Desire to decrease the number of frustrating Runtime Errors encountered during experiment execution.
99

1010
> [!NOTE]
11-
> This repo is under construction.
11+
> This repo is under construction.
1212
13+
## Pull Requests
14+
A PR typically implements a new feature, improves an old feature, or fixes a bug.
1315

1416
## Typing
1517
### Static type checking
@@ -21,4 +23,4 @@ This template, designed as the optimal springboard for your open-source Python r
2123

2224
## Contribution
2325

24-
I welcome all kinds of contribution, e.g. adding more tools, better practices, discussions on trade-offs.
26+
I welcome all kinds of contribution, e.g. adding more tools, better practices, discussions on trade-offs.

0 commit comments

Comments
 (0)