Skip to content

Commit d334d78

Browse files
titouancdpgeorge
authored andcommitted
tools/verifygitlog.py: Show required format regexp in error message.
Signed-off-by: iTitou <moiandme@gmail.com>
1 parent 03a64f2 commit d334d78

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

tools/verifygitlog.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,9 @@ def warning(err):
5757
# Subject line.
5858
subject_line = raw_body[0]
5959
very_verbose("subject_line", subject_line)
60-
if not re.match(r"^[^!]+: [A-Z]+.+ .+\.$", subject_line):
61-
error("Subject line should contain ': ' and end in '.': " + subject_line)
60+
subject_line_format = r"^[^!]+: [A-Z]+.+ .+\.$"
61+
if not re.match(subject_line_format, subject_line):
62+
error("Subject line should match " + repr(subject_line_format) + ": " + subject_line)
6263
if len(subject_line) >= 73:
6364
error("Subject line should be 72 or less characters: " + subject_line)
6465

0 commit comments

Comments
 (0)