|
| 1 | +# |
| 2 | +# Format |
| 3 | +# |
| 4 | +# ACTION: [AUDIENCE:] COMMIT_MSG [@TAG ...] |
| 5 | +# |
| 6 | +# Description |
| 7 | +# |
| 8 | +# ACTION is one of 'chg', 'fix', 'new' |
| 9 | +# |
| 10 | +# Is WHAT the change is about. |
| 11 | +# |
| 12 | +# 'chg' is for refactor, small improvement, cosmetic changes... |
| 13 | +# 'fix' is for bug fixes |
| 14 | +# 'new' is for new features, big improvement |
| 15 | +# |
| 16 | +# SUBJECT is optional and one of 'dev', 'usr', 'pkg', 'test', 'doc' |
| 17 | +# |
| 18 | +# Is WHO is concerned by the change. |
| 19 | +# |
| 20 | +# 'dev' is for developpers (API changes, refactors...) |
| 21 | +# 'usr' is for final users (UI changes) |
| 22 | +# 'pkg' is for packagers (packaging changes) |
| 23 | +# 'test' is for testers (test only related changes) |
| 24 | +# 'doc' is for doc guys (doc only changes) |
| 25 | +# |
| 26 | +# COMMIT_MSG is ... well ... the commit message itself. |
| 27 | +# |
| 28 | +# TAGs are additionnal adjective as 'refactor' 'minor' 'cosmetic' |
| 29 | +# |
| 30 | +# 'refactor' is obviously for refactoring code only |
| 31 | +# 'minor' is for a very meaningless change (a typo, adding a comment) |
| 32 | +# 'cosmetic' is for cosmetic driven change (re-indentation, 80-col...) |
| 33 | +# |
| 34 | +# Example: |
| 35 | +# |
| 36 | +# new: usr: support of bazaar implemented |
| 37 | +# chg: re-indentend some lines @cosmetic |
| 38 | +# new: dev: updated code to be compatible with last version of killer lib. |
| 39 | +# fix: pkg: updated year of licence coverage. |
| 40 | +# new: test: added a bunch of test around user usability of feature X. |
| 41 | +# fix: typo in spelling my name in comment. @minor |
| 42 | +# |
| 43 | +# Please note that multi-line commit message are supported, and only the |
| 44 | +# first line will be considered as the "summary" of the commit message. So |
| 45 | +# tags, and other rules only applies to the summary. The body of the commit |
| 46 | +# message will be displayed in the changelog with minor reformating. |
| 47 | + |
| 48 | +# |
| 49 | +# ``ignore_regexps`` is a line of regexps |
| 50 | +# |
| 51 | +# Any commit having its full commit message matching any regexp listed here |
| 52 | +# will be ignored and won't be reported in the changelog. |
| 53 | +# |
| 54 | +ignore_regexps = [ |
| 55 | + r'(?i)^(Merge pull request|Merge branch|Release|Update)', |
| 56 | +] |
| 57 | + |
| 58 | + |
| 59 | +# |
| 60 | +# ``replace_regexps`` is a dict associating a regexp pattern and its replacement |
| 61 | +# |
| 62 | +# It will be applied to get the summary line from the full commit message. |
| 63 | +# |
| 64 | +# Note that you can provide multiple replacement patterns, they will be all |
| 65 | +# tried. If None matches, the summary line will be the full commit message. |
| 66 | +# |
| 67 | +replace_regexps = { |
| 68 | + # current format (ie: 'chg: dev: my commit msg @tag1 @tag2') |
| 69 | + |
| 70 | + r'^([cC]hg|[fF]ix|[nN]ew)\s*:\s*((dev|use?r|pkg|test|doc)\s*:\s*)?([^\n@]*)(@[a-z]+\s+)*$': |
| 71 | + r'\4', |
| 72 | +} |
| 73 | + |
| 74 | + |
| 75 | +# ``section_regexps`` is a list of 2-tuples associating a string label and a |
| 76 | +# list of regexp |
| 77 | +# |
| 78 | +# Commit messages will be classified in sections thanks to this. Section |
| 79 | +# titles are the label, and a commit is classified under this section if any |
| 80 | +# of the regexps associated is matching. |
| 81 | +# |
| 82 | +section_regexps = [ |
| 83 | + ('New', [ |
| 84 | + r'^[nN]ew\s*:\s*((dev|use?r|pkg|test|doc)\s*:\s*)?([^\n]*)$', |
| 85 | + ]), |
| 86 | + ('Changes', [ |
| 87 | + r'^[cC]hg\s*:\s*((dev|use?r|pkg|test|doc)\s*:\s*)?([^\n]*)$', |
| 88 | + ]), |
| 89 | + ('Fix', [ |
| 90 | + r'^[fF]ix\s*:\s*((dev|use?r|pkg|test|doc)\s*:\s*)?([^\n]*)$', |
| 91 | + ]), |
| 92 | + ('Other', None # Match all lines |
| 93 | + ), |
| 94 | + |
| 95 | +] |
| 96 | + |
| 97 | +# ``body_split_regexp`` is a regexp |
| 98 | +# |
| 99 | +# Commit message body (not the summary) if existing will be split |
| 100 | +# (new line) on this regexp |
| 101 | +# |
| 102 | +body_split_regexp = r'[\n-]' |
| 103 | + |
| 104 | + |
| 105 | +# ``tag_filter_regexp`` is a regexp |
| 106 | +# |
| 107 | +# Tags that will be used for the changelog must match this regexp. |
| 108 | +# |
| 109 | +# tag_filter_regexp = r'^[0-9]+$' |
| 110 | +tag_filter_regexp = r'^(?:[vV])?[0-9\.]+$' |
| 111 | + |
| 112 | + |
| 113 | +# ``unreleased_version_label`` is a string |
| 114 | +# |
| 115 | +# This label will be used as the changelog Title of the last set of changes |
| 116 | +# between last valid tag and HEAD if any. |
| 117 | +unreleased_version_label = "%%version%% (unreleased)" |
0 commit comments