aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorB. Watson <urchlay@slackware.uk>2023-05-19 02:36:48 -0400
committerB. Watson <urchlay@slackware.uk>2023-05-19 02:36:48 -0400
commit7c77573f443e88c54b1a11376892894d52c500e2 (patch)
treee112c63e548e4b8201d282b55459cc837fcce691
parent7bb8997041b0cc3996e03b48e36e132cdc4a434e (diff)
downloadsbo-maintainer-tools-7c77573f443e88c54b1a11376892894d52c500e2.tar.gz
sbolint: check for trailing whitespace in slack-desc description lines.
-rwxr-xr-xsbolint9
1 files changed, 7 insertions, 2 deletions
diff --git a/sbolint b/sbolint
index 9e16dea..34d156f 100755
--- a/sbolint
+++ b/sbolint
@@ -867,10 +867,15 @@ sub check_slackdesc {
log_error("slack-desc:$lineno: wrong prefix '$prefix', should be '$buildname:'");
} elsif($text =~ /^\s+$/) {
log_error("slack-desc:$lineno: trailing whitespace after colon, on otherwise-blank line");
- } elsif(length($text) > 71) {
- log_error("slack-desc:$lineno: text too long, %d characters, should be <= 71", length($text));
} elsif(length($text) && $text !~ /^ /) {
log_error("slack-desc:$lineno: missing whitespace after colon, on non-blank line");
+ } else {
+ if($text =~ /\s$/) {
+ log_error("slack-desc:$lineno: trailing whitespace on description line");
+ }
+ if(length($text) > 71) {
+ log_error("slack-desc:$lineno: text too long, %d characters, should be <= 71", length($text));
+ }
}
my $bn = quotemeta($buildname); # some builds have + in the name