summaryrefslogtreecommitdiff
path: root/tools/verifygitlog.py
diff options
context:
space:
mode:
authorDavid Lechner <david@pybricks.com>2022-02-09 11:02:12 -0600
committerDamien George <damien@micropython.org>2022-02-18 14:33:33 +1100
commit5d6408f8f914f46f3c067fc59f5f31001b988fbc (patch)
treedd79841d1f181554aca26b3f3c3827c9cea77b46 /tools/verifygitlog.py
parent28cb573b89f3d1edfff786f8ee757a93579c41bd (diff)
tools/verifygitlog.py: Ignore line length in body if it's a URL.
This changes the git commit message line length check to ignore lines that contain URLs, since these cannot be wrapped without breaking tools that detect URLs and create a link. Signed-off-by: David Lechner <david@pybricks.com>
Diffstat (limited to 'tools/verifygitlog.py')
-rwxr-xr-xtools/verifygitlog.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/verifygitlog.py b/tools/verifygitlog.py
index cc4b80f4a..ce3679125 100755
--- a/tools/verifygitlog.py
+++ b/tools/verifygitlog.py
@@ -69,7 +69,8 @@ def verify(sha):
# Message body lines.
for line in raw_body[2:]:
- if len(line) >= 76:
+ # Long lines with URLs are exempt from the line length rule.
+ if len(line) >= 76 and "://" not in line:
error("Message lines should be 75 or less characters: " + line)
if not raw_body[-1].startswith("Signed-off-by: ") or "@" not in raw_body[-1]: