diff --git a/contrib/commandref_join.pl b/contrib/commandref_join.pl index 61f67a9d8..2d259126d 100755 --- a/contrib/commandref_join.pl +++ b/contrib/commandref_join.pl @@ -65,16 +65,18 @@ foreach my $lang (@lang) { open(MOD, $mods{$mod}) || die("Cant open $mods{$mod}:$!\n"); my $skip = 1; my $line = 0; + my $docCount = 0; while(my $l = ) { $line++; - if($l =~ m/^=begin html$suffix/) { + if($l =~ m/^=begin html$suffix$/) { $l = ; # skip one line, to be able to repeat join+split $skip = 0; $line++; - } elsif($l =~ m/^=end html$suffix/) { + } elsif($l =~ m/^=end html$suffix$/) { $skip = 1; } elsif(!$skip) { # here we copy line by line from the module print OUT $l; + $docCount++; foreach $tag (TAGS) { my $ot = ($tagcount{$tag} ? $tagcount{$tag} : 0); $tagcount{$tag} +=()= ($l =~ /<$tag>/gi); @@ -85,6 +87,7 @@ foreach my $lang (@lang) { } } close(MOD); + print "$mod: No document text found\n" if(!$suffix && !$docCount); foreach $tag (TAGS) { print("$lang $mods{$mod}: Unbalanced $tag ". "($tagcount{$tag}, last line ok: $llwct{$tag})\n")