Skip to content

Commit b9609ec

Browse files
mchehabJonathan Corbet
authored andcommitted
scripts/kernel-doc: don't add not needed new lines
This helps comparing kernel-doc output with the new .py version of it. Signed-off-by: Mauro Carvalho Chehab <[email protected]> Link: https://lore.kernel.org/r/6b036ef7d746f26d7d0044626b04d1f0880a2188.1740387599.git.mchehab+huawei@kernel.org Signed-off-by: Jonathan Corbet <[email protected]>
1 parent 99326b2 commit b9609ec

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

scripts/kernel-doc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -760,6 +760,10 @@ sub output_highlight_rst {
760760
if ($block) {
761761
$output .= highlight_block($block);
762762
}
763+
764+
$output =~ s/^\n+//g;
765+
$output =~ s/\n+$//g;
766+
763767
foreach $line (split "\n", $output) {
764768
print $lineprefix . $line . "\n";
765769
}

0 commit comments

Comments
 (0)