1# All these sections are optional. Each section with the exception of [general] represents
2# one rule and each key in it is an option for that specific rule.
3#
4# Rules and sections can be referenced by their full name or by id. For example
5# section "[body-max-line-length]" could also be written as "[B1]". Full section names are
6# used in here for clarity.
7#
8[general]
9# Ignore body-max-line-length and body-hard-tab and rely on the custom
10# OpenBMC-specific rule that covers both of these rules.
11ignore=body-max-line-length,body-hard-tab
12
13# verbosity should be a value between 1 and 3, the commandline -v flags take precedence over this
14# verbosity = 2
15
16# By default gitlint will ignore merge, revert, fixup and squash commits.
17# ignore-merge-commits=true
18# ignore-revert-commits=true
19# ignore-fixup-commits=true
20# ignore-squash-commits=true
21
22# Ignore any data send to gitlint via stdin
23# ignore-stdin=true
24
25# Fetch additional meta-data from the local repository when manually passing a
26# commit message to gitlint via stdin or --commit-msg. Disabled by default.
27# staged=true
28
29# Hard fail when the target commit range is empty. Note that gitlint will
30# already fail by default on invalid commit ranges. This option is specifically
31# to tell gitlint to fail on *valid but empty* commit ranges.
32# Disabled by default.
33# fail-without-commits=true
34
35# Enable debug mode (prints more output). Disabled by default.
36# debug=true
37
38# Enable community contributed rules
39# See http://jorisroovers.github.io/gitlint/contrib_rules for details
40# contrib=contrib-title-conventional-commits,CC1
41
42# Set the extra-path where gitlint will search for user defined rules
43# See http://jorisroovers.github.io/gitlint/user_defined_rules for details
44# extra-path=examples/
45
46# set the title line-length to 72
47[title-max-length]
48line-length=72
49
50# Conversely, you can also enforce minimal length of a title with the
51# "title-min-length" rule:
52[title-min-length]
53min-length=5
54
55[title-must-not-contain-word]
56# Comma-separated list of words that should not occur in the title. Matching is case
57# insensitive. It's fine if the keyword occurs as part of a larger word (so "WIPING"
58# will not cause a violation, but "WIP: my title" will.
59words=
60
61# [title-match-regex]
62# python-style regex that the commit-msg title must match
63# Note that the regex can contradict with other rules if not used correctly
64# (e.g. title-must-not-contain-word).
65# regex=^US[0-9]*
66
67[body-max-line-length-with-exceptions]
68line-length=72
69
70#[body-min-length]
71#min-length=100
72
73[body-is-missing]
74# Whether to ignore this rule on merge commits (which typically only have a title)
75ignore-merge-commits=false
76
77# [body-changed-file-mention]
78# List of files that need to be explicitly mentioned in the body when they are changed
79# This is useful for when developers often erroneously edit certain files or git submodules.
80# By specifying this rule, developers can only change the file when they explicitly reference
81# it in the commit message.
82# files=gitlint-core/gitlint/rules.py,README.md
83
84# [body-match-regex]
85# python-style regex that the commit-msg body must match.
86# E.g. body must end in My-Commit-Tag: foo
87# regex=My-Commit-Tag: foo$
88
89# [author-valid-email]
90# python-style regex that the commit author email address must match.
91# For example, use the following regex if you only want to allow email addresses from foo.com
92# regex=[^@]+@foo.com
93
94# [ignore-by-title]
95# Ignore certain rules for commits of which the title matches a regex
96# E.g. Match commit titles that start with "Release"
97# regex=^Release(.*)
98
99# Ignore certain rules, you can reference them by their id or by their full name
100# Use 'all' to ignore all rules
101# ignore=T1,body-min-length
102
103# [ignore-by-body]
104# Ignore certain rules for commits of which the body has a line that matches a regex
105# E.g. Match bodies that have a line that that contain "release"
106# regex=(.*)release(.*)
107#
108# Ignore certain rules, you can reference them by their id or by their full name
109# Use 'all' to ignore all rules
110# ignore=T1,body-min-length
111
112#[ignore-body-lines]
113#regex=^Signed-off-by:
114#ignore=body-max-line-length
115
116# [ignore-by-author-name]
117# Ignore certain rules for commits of which the author name matches a regex
118# E.g. Match commits made by dependabot
119# regex=(.*)dependabot(.*)
120#
121# Ignore certain rules, you can reference them by their id or by their full name
122# Use 'all' to ignore all rules
123# ignore=T1,body-min-length
124
125# This is a contrib rule - a community contributed rule. These are disabled by default.
126# You need to explicitly enable them one-by-one by adding them to the "contrib" option
127# under [general] section above.
128# [contrib-title-conventional-commits]
129# Specify allowed commit types. For details see: https://www.conventionalcommits.org/
130# types = bugfix,user-story,epic
131