Commit 0b0bb9e8 authored by acud's avatar acud Committed by GitHub

ci: enforce conventional commits (#1684)

parent 8598ed22
...@@ -28,7 +28,10 @@ jobs: ...@@ -28,7 +28,10 @@ jobs:
- name: Checkout - name: Checkout
uses: actions/checkout@v2 uses: actions/checkout@v2
with: with:
fetch-depth: 1 fetch-depth: 0
- name: Commit linting
if: matrix.os == 'ubuntu-latest'
uses: wagoid/commitlint-github-action@v2
- name: Cache Go modules - name: Cache Go modules
uses: actions/cache@v1 uses: actions/cache@v1
with: with:
......
module.exports = {
parserPreset: 'conventional-changelog-conventionalcommits',
rules: {
'body-leading-blank': [2, 'always'],
'body-max-line-length': [2, 'always', 72],
'body-case': [
2,
'never',
['sentence-case', 'start-case', 'pascal-case', 'upper-case'],
],
'footer-leading-blank': [1, 'always'],
'footer-max-line-length': [2, 'always', 72],
'header-max-length': [2, 'always', 72],
'subject-case': [
2,
'never',
['sentence-case', 'start-case', 'pascal-case', 'upper-case'],
],
'subject-empty': [2, 'never'],
'subject-full-stop': [2, 'never', '.'],
'type-case': [2, 'always', 'lower-case'],
'type-empty': [2, 'never'],
'type-enum': [
2,
'always',
[
'build',
'chore',
'ci',
'docs',
'feat',
'fix',
'perf',
'refactor',
'revert',
'test',
],
],
},
};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment