-
Notifications
You must be signed in to change notification settings - Fork 56
45 lines (42 loc) · 1.16 KB
/
validate_pr.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-syntax-for-github-actions
name: "Validate PR"
on:
pull_request_target:
types:
- opened
- edited
- synchronize
jobs:
build:
permissions:
contents: read
pull-requests: write
runs-on: ubuntu-latest
steps:
- name: "Validate semantic PR title"
uses: amannn/action-semantic-pull-request@v5 # https://github.com/amannn/action-semantic-pull-request
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
# https://mazer.dev/en/git/best-practices/git-semantic-commits/
# https://github.com/commitizen/conventional-commit-types/blob/master/index.json
types: |
build
ci
chore
docs
fix
feat
refact
revert
perf
style
scopes: |
core
deps
ui
requireScope: false
- name: "Label PR"
uses: srvaroa/labeler@v1.6.1 # https://github.com/srvaroa/labeler
env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"