aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorB. Watson <urchlay@slackware.uk>2026-05-23 15:15:04 -0400
committerB. Watson <urchlay@slackware.uk>2026-05-23 15:15:04 -0400
commite07288b7cf47387028df470f8fdf71f57182e345 (patch)
tree4edab0f23d1df40b0f79810c5c41e59415573923
parentf997fbf9c90ace622d97cd7d2960ed3bff915d57 (diff)
downloadsbo-maintainer-tools-e07288b7cf47387028df470f8fdf71f57182e345.tar.gz
Do not complain about no newline at EOF for patch/diff files.
-rwxr-xr-xsbolint13
1 files changed, 6 insertions, 7 deletions
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;
}