-
Notifications
You must be signed in to change notification settings - Fork 0
44 lines (32 loc) · 1020 Bytes
/
commitlint.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
# Will lint commits only on pull requests. It should be possible to use an old codebase which does
# not follow a commit convention.
name: Commit Convention Check
on:
pull_request:
branches: [main]
types: [opened, synchronize, reopened]
jobs:
commitlint:
continue-on-error: true
name: Validate all Commit Messages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: '16.x'
cache: 'npm'
- name: Install dependencies
run: npm ci
- name: Validate all commits from PR
run: 'npx commitlint --from ${{ github.event.pull_request.base.sha }} --to ${{ github.event.pull_request.head.sha }} --verbose'
pr-title:
name: Validate PR title
runs-on: ubuntu-latest
steps:
- uses: amannn/action-semantic-pull-request@v3.4.6
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}