This configuration is extending @commitlint/config-conventional. Only the changed and added rules, compared to @commitlint/config-conventional, are documented here.
- condition:
body
each line hasvalue
or less characters. - level:
disabled
.
- condition:
footer
lines hasvalue
or less characters. - level:
disabled
. - value: n/a
- condition:
header
hasvalue
or less characters. - level:
disabled
. - value: n/a
-
condition:
header
hasvalue
or less characters. -
level:
error
. -
rule:
always
. -
value: The value is dependent on the commit header and has the following values.
- Default.
100
- If
header
has one of the prefixes listed below.chore(deps)
, for Renovate and Dependabot.fix(deps)
, for Renovate.build(deps)
, for Dependabot.chore(deps-dev)
, for Dependabot.build(deps-dev)
, for Dependabot.
200
- Default.
Note
Regular commits have the default header length and fail if the header is too long.
$ echo 'chore: knowledge, like air, is vital to life. Like air, no one should be denied it. - Alan Moore' | npx commitlint # passes, 96 characters
$ echo 'chore: knowledge, like air, is vital to life. Like air, no one should be denied it. - Alan Moore, V for Vendetta' | npx commitlint # fails, 112 characters
Renovate and Dependabot commits have extended header length.
$ echo 'chore(deps): we are told to remember the idea, not the man. Because a man can fail. He can be caught, he can be killed and forgotten. But 400 years later, an idea can still change the world - A. Moore' | npx commitlint # passes, 200 characters
$ echo 'chore(deps): we are told to remember the idea, not the man. Because a man can fail. He can be caught, he can be killed and forgotten. But 400 years later, an idea can still change the world - Alan Moore' | npx commitlint # fails, 202 characters