forked from Ethereal-Future/FuTuRe
-
Notifications
You must be signed in to change notification settings - Fork 0
33 lines (28 loc) · 1.03 KB
/
Copy pathcommitlint.yml
File metadata and controls
33 lines (28 loc) · 1.03 KB
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
name: Commit Lint
# Validate commit messages on every PR against Conventional Commits.
# Merge commits and release-please bot commits are automatically skipped.
on:
pull_request:
branches: [main, master, develop]
types: [opened, synchronize, reopened, edited]
jobs:
commitlint:
name: Lint Commit Messages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
# Fetch enough history to lint all commits in the PR
fetch-depth: 0
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.3.0
with:
node-version: "20"
cache: npm
- name: Install commitlint
run: npm install --save-dev @commitlint/cli@19 @commitlint/config-conventional@19
- name: Lint commits from base to HEAD
run: |
npx commitlint \
--from "${{ github.event.pull_request.base.sha }}" \
--to "${{ github.event.pull_request.head.sha }}" \
--verbose