From e07288b7cf47387028df470f8fdf71f57182e345 Mon Sep 17 00:00:00 2001 From: "B. Watson" Date: Sat, 23 May 2026 15:15:04 -0400 Subject: Do not complain about no newline at EOF for patch/diff files. --- sbolint | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'sbolint') diff --git a/sbolint b/sbolint index ce08f09..8166f39 100755 --- a/sbolint +++ b/sbolint @@ -818,15 +818,14 @@ sub check_and_read { } } - if($crlf_err) { - if($file =~ /\.(diff|patch)$/i) { - log_error("$file has DOS-style CRLF line endings, git will mess it up unless you gzip it!") if $crlf_err; - } else { - log_error("$file has DOS-style CRLF line endings") if $crlf_err; - } + if($file =~ /\.(diff|patch)$/i) { + log_error("$file has DOS-style CRLF line endings, git will mess it up unless you gzip it!") if $crlf_err; + # 20260523 bkw: do not complain if patches lack EOF at end! + } else { + log_error("$file has DOS-style CRLF line endings") if $crlf_err; + log_error("$file has no newline at EOF") if $lastline_nonl; } - log_error("$file has no newline at EOF") if $lastline_nonl; return @lines; } -- cgit v1.2.3