On 9/30/26 12:22 PM, Ales Musil wrote:
> On Wed, Sep 30, 2026 at 11:46 AM Dumitru Ceara <[email protected]> wrote:
>
>> On 9/29/26 1:00 PM, Ales Musil wrote:
>>> Long commit message lines are difficult to read after git and email add
>>> indentation or quotation prefixes. Enforce the documented 75-character
>>> limit while allowing Git-style trailers to remain unwrapped.
>>>
>>> Add coverage for boundary values, trailer exemptions, and raw email
>>> input.
>>>
>>> Assisted-by: GPT-5.6-Sol, OpenCode
>>> Signed-off-by: Ales Musil <[email protected]>
>>> ---
>>
>> Hi Ales,
>>
>>
> Hi Dumitru,
>
>
>>> tests/checkpatch.at | 103 ++++++++++++++++++++++++++++++++++++++++
>>> utilities/checkpatch.py | 16 ++++++-
>>> 2 files changed, 117 insertions(+), 2 deletions(-)
>>>
...
>>> @@ -1022,6 +1028,7 @@ def ovs_checkpatch_parse(text, filename,
>> author=None, committer=None):
>>> elif is_author.match(line):
>>> author = is_author.match(line).group(2)
>>> elif is_subject.match(line):
>>> + subject_seen = True
>>> run_subject_checks(line, spellcheck)
>>> elif is_signature.match(line):
>>> m = is_signature.match(line)
>>> @@ -1041,6 +1048,11 @@ def ovs_checkpatch_parse(text, filename,
>> author=None, committer=None):
>>> '--pretty=format:"Fixes: %h (\\\"%s\\\")" '
>>> '--abbrev=12 COMMIT_REF\n')
>>> print("%d: %s\n" % (lineno, line))
>>> + elif (in_commit_body and len(line) > 75
>>> + and not is_trailer.match(line)):
>>> + print_warning("Commit message body line is %d
>> characters "
>>> + "long (recommended limit is 75)" %
>> len(line))
>>> + print("%d: %s\n" % (lineno, line))
>>> elif spellcheck:
>>> check_spelling(line, False)
>>
>> We'd skip spell checking for long lines. That's not that bad but we
>> could probably fix it if we do:
>>
>> else:
>> if (in_commit_body and len(line) > 75
>> and not is_trailer.match(line)):
>> print_warning("Commit message body line is %d
>> characters "
>> "long (recommended limit is 75)" %
>> len(line))
>> print("%d: %s\n" % (lineno, line))
>> if spellcheck:
>> check_spelling(line, False)
>>
>> I can fold that in, what do you think?
>>
>
> fine by me.
>
Cool, I squashed that in and applied the patch to main.
Regards,
Dumitru
>
>>
>>> for typo, correct in tags_typos.items():
>>> @@ -1138,7 +1150,7 @@ def ovs_checkpatch_file(filename):
>>> continue
>>> result = ovs_checkpatch_parse(part.get_payload(decode=False),
>> filename,
>>> mail.get('Author', mail['From']),
>>> - mail['Commit'])
>>> + mail['Commit'], body_only=True)
>>>
>>> if not mail['Subject'] or not mail['Subject'].strip():
>>> if mail['Subject']:
>>
>> Regards,
>> Dumitru
>>
>>
> Thanks,
> Ales
>
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev